Mageia Bugzilla – Attachment 10077 Details for
Bug 22855
cfitsio new security issues fixed upstream in 3.43 (including CVE-2018-1000166)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
Entry level script for examining a FITS data file.
example.c (text/plain), 757 bytes, created by
Len Lawrence
on 2018-04-05 14:29:51 CEST
(
hide
)
Description:
Entry level script for examining a FITS data file.
Filename:
MIME Type:
Creator:
Len Lawrence
Created:
2018-04-05 14:29:51 CEST
Size:
757 bytes
patch
obsolete
> #include <string.h> > #include <stdio.h> > #include "fitsio.h" > > int main(int argc, char *argv[]) > { > fitsfile *fptr; > char card[FLEN_CARD]; > int status = 0, nkeys, ii; /* MUST initialize status */ > > fits_open_file(&fptr, argv[1], READONLY, &status); > fits_get_hdrspace(fptr, &nkeys, NULL, &status); > > for (ii = 1; ii <= nkeys; ii++) { > fits_read_record(fptr, ii, card, &status); /* read keyword */ > printf("%s\n", card); > } > printf("END\n\n"); /* terminate listing with END */ > fits_close_file(fptr, &status); > > if (status) /* print any error messages */ > fits_report_error(stderr, status); > return(status); > }
#include <string.h> #include <stdio.h> #include "fitsio.h" int main(int argc, char *argv[]) { fitsfile *fptr; char card[FLEN_CARD]; int status = 0, nkeys, ii; /* MUST initialize status */ fits_open_file(&fptr, argv[1], READONLY, &status); fits_get_hdrspace(fptr, &nkeys, NULL, &status); for (ii = 1; ii <= nkeys; ii++) { fits_read_record(fptr, ii, card, &status); /* read keyword */ printf("%s\n", card); } printf("END\n\n"); /* terminate listing with END */ fits_close_file(fptr, &status); if (status) /* print any error messages */ fits_report_error(stderr, status); return(status); }
View Attachment As Raw
Actions:
View
Attachments on
bug 22855
: 10077