amazing weirdness! !PATH screwed up MEAN function [message #82120] |
Mon, 19 November 2012 22:52 |
MarioIncandenza
Messages: 231 Registered: February 2005
|
Senior Member |
|
|
What happened was this:
I mistakenly created a symbolic link that pointed to the directory in which the link was located, creating an infinite recursion. When I asked IDL to scan the path using EXPAND_PATH(), it did so, and added the results to !PATH like I asked with no error. When I did PRINT,!PATH it appears that the recursed link is repeated perhaps 100x and then it goes on to other paths.
Then it did this:
IDL> help,moment(indgen(1e4))
<Expression> FLOAT = Array[4]
IDL> help,mean(indgen(1e4))
<Expression> FLOAT = Array[10000]
For what it's worth, all of the 1e4 values returned by MEAN() were -2.2.
I exited IDL and restarted, and was able to reproduce this behavior. My best guess is that the screwed-up !PATH somehow walked over the memory that was supposed to have the MEAN() function, some sort of buffer overflow thing, but I don't know.
When the offending symlink was removed, the problem went away.
For the record,
IDL> print,!version
{ x86_64 linux unix linux 7.1.1 Aug 21 2009 64 64}
Back to my more routine questioning of my sanity.
|
|
|