/* Set open file's I/O descriptor, and return previous value.  */
int TIFFSetFileno(TIFF *tif, int fd)
/* Set open file's I/O descriptor, and return previous value.  */
int TIFFSetFileno(TIFF *tif, int fd)
{
        int old_fd = tif->tif_fd;
	tif->tif_fd = fd;
	return old_fd;
}