comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » IDL 5.3 serious problem: save files sneakily restored
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
IDL 5.3 serious problem: save files sneakily restored [message #21391] Thu, 24 August 2000 00:00 Go to previous message
kashyap is currently offline  kashyap
Messages: 26
Registered: April 1993
Junior Member
IDL 5.3 appears to have a major hull breach.

If there is an idl save file named "<whatever>.sav" in the current
directory,
the contents of that file get restored whenever <whatever> is referenced as
a function within IDL.

<whatever> does not have to be a string.
It must have the ".sav" extension, and must be a valid IDL save file.

This is very dangerous, because there is no telling when local variables
will suddenly get overwritten.

I checked the online help documentation and didn't see anything about
this immediately. Even if it is a documented feature, it's a mistake.

This was discovered because we have a function called fitlines.pro
which wasn't being run because there was a goddammed savefile called
fitlines.sav in the current directory.

The log of a demonstration is appended below.

Comments?

Vinay
____________________________________________________________ __________

suppose, in the current directory, there are some IDL savefiles:
(which were made say, as follows:
idl
IDL> x=findgen(100)
IDL> save,file='whatever.sav'
IDL> y=x^2
IDL> save,file='kursk.sav'
IDL> exit
)

Then, when you start IDL and say

idl
IDL> print,!version
{ sparc sunos unix 5.3 Nov 11 1999}
IDL> help
% At $MAIN$
Compiled Procedures:
$MAIN$

Compiled Functions:

IDL> help,whatever()
% Restored file: WHATEVER.
% Attempt to call undefined procedure/function: 'WHATEVER'.
% Execution halted at: $MAIN$
IDL> help
% At $MAIN$
X FLOAT = Array[100]
Compiled Procedures:
$MAIN$
Compiled Functions:


IDL> tmp=kursk()
% Restored file: KURSK.
% Attempt to call undefined procedure/function: 'KURSK'.
% Execution halted at: $MAIN$
IDL> help
% At $MAIN$
TMP UNDEFINED = <Undefined>
X FLOAT = Array[100]
Y FLOAT = Array[100]
Compiled Procedures:
$MAIN$

Compiled Functions:


IDL>

--
____________________________________________________________ __________________
kashyap@head-cfa.harvard.edu 617 495 7173 [CfA/P-146] 617 496 7173 [F]
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: LINKLOAD, aix, pv-wave?
Next Topic: Re: TWO DIFFERENT COLOR TABLES IN SAME WINDOW

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 06:07:05 PDT 2025

Total time taken to generate the page: 0.87640 seconds