bugGNU Astronomy Utilities - Bugs: bug #62861, printkeynames gets caught in an...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #62861: printkeynames gets caught in an infinite loop

Submitter:  Pedram Ashofteh-Ardakani <pedram>
Submitted:  Thu 04 Aug 2022 07:38:47 AM UTC
   
 
Category:  Fits Severity:  3 - Normal
Item Group:  Crash Status:  Fixed
Privacy:  Public Assigned to:  makhlaghi
Open/Closed:  Closed

Thu 04 Aug 2022 08:38:26 AM UTC, comment #2: 

What a quick fix :-D

That was interesting! I really like how well you have kept these problems documented :)

I tried grep*ing the entire source code for other instances of *strcmp with END, but it looks like these two (keywords.c and fits.c) were the only files.

With that said, I'll close this bug and set it as fixed, thanks!

Pedram Ashofteh-Ardakani <pedram>
Group Member
Thu 04 Aug 2022 08:14:47 AM UTC, comment #1: 

Thanks a lot for the wonderful bug report Pedram, it has been fixed.

Fortunately we had encountered a similar problem a few weeks ago with older FITS files that have empty keys before the 'END' keyword (see the description of Commit 5f1d2c73), so the fix (Commit 060f4e6c7) was easy :-).

Mohammad Akhlaghi <makhlaghi>
Group administrator
Thu 04 Aug 2022 07:38:47 AM UTC, original submission:  

What is the Problem


It looks like that astfits gets caught in an infinite loop when printkeynames switch is on for the standard tpv.fits file from NASA. It does print all keynames, however, it doesn't let go of the command prompt and the CPU usage shoots up to 100%.

What did I Expect


Exit after printing all keynames.

Steps to Reproduce



$ wget "https://fits.gsfc.nasa.gov/registry/tpvwcs/tpv.fits" -O tpv.fits
$ astfits tpv.fits -h0 --printkeynames


Version


Fits (GNU Astronomy Utilities) 0.17.94-b3c7


Pedram Ashofteh-Ardakani <pedram>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by makhlaghi (Posted a comment)
  • -email is unavailable- added by pedram (Submitted the item)
  • -email is unavailable- added by pedram
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-08-04 makhlaghi StatusNone Fixed
        Assigned toNone makhlaghi
        Open/ClosedOpen Closed
    2022-08-04 pedram Carbon-Copy- Added makhlaghi

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code