cfitsio: use resource