Small-Bodies-Node/PDS4-IDL

Error reading table

Closed this issue · 1 comments

A reviewer attempted to read a label from yesterday's review, but the program crashed. The files they were using: pds4-review.zip. Their report:

Data files can not be read using READ_PDS on the .xml files. Here the error message produced by READ_PDS:

water_c_103p_hartley_2_1997.xml
read_pds: Data file is ./water_c_103p_hartley_2_1997.tab
Error index: -198
Error message: Variable is undefined: TABLEN.

Here is the relevant lines in read_pds.pro:
ELSE $
table_name = tablen

the variable “tablen” appears nowhere prior in the code, so naturally it is undefined at this point, and the code crashes. Since The code would not run, I can not verify whether the XML files are valid or not. There are however, additional issues with either the code or the provided xml files, as read_pds will crash on the very next line, if you just skip the suspect tablen definition line.

Also, line 126 of READ_PDS.pro is missing a closing single quote mark —still works, but messes up colorization.

Fix addressed in PR #8 .