[fitsbits] where should END keyword be placed?

Michal Szymanski msz at tucana.astrouw.edu.pl
Fri Apr 21 06:50:23 EDT 2000


The latest release of IRAF package (2.11.3) introduced (I'm not quite
sure if it has not appeared earlier but surely was not so in 2.10.x)
a change in the way the header of a FITS file is written. The END
keyword is placed not directly after the last record of the header but
in the last 80-bytes record of current 2880-bytes chunk. In other words,
the "empty" space in the last 2880 bytes is filled up not after END
record but before it.

This has broken some of my applications which add new keywords (in a
sense that they start to add new 2880 bytes block although there is
still space for new keywords). I had to change the code to check
for "free" records before END record.

At first I thought this is a (new?) requirement of FITS standard but
when I downloaded latest (v. 2.0.36) "cfitsio" library and made a simple
test I found that the library routines place END record in a
"traditional" way, right after last header record and fill it up to next
2880 bytes *after* END.

The question is: are both approaches standard-conformant?

regards, Michal.

-- 
  Michal Szymanski (msz at astrouw.edu.pl)
  Warsaw University Observatory, Warszawa, POLAND



More information about the fitsbits mailing list