rem: printf("First IFD: 0x%.8lx\n", firstIFDOffset);
context: identify_tiff_header(BPositionIO *inSource, translator_info *outInfo,	ssize_t amtread, uint8 *read, swap_action swp,	TiffDetails *pdetails = NULL){	if (amtread != 4)		return B_ERROR;			uint32 firstIFDOffset = 0;	ssize_t nread = inSource->Read(&firstIFDOffset, 4);	if (nread != 4) {		printf("Unable to read first IFD offset\n");		return B_NO_TRANSLATOR;	}	if (swap_data(B_UINT32_TYPE, &firstIFDOffset,		sizeof(uint32), swp) != B_OK) {		printf("swap_data() error\n");		return B_ERROR;	}	printf("First IFD: 0x%.8lx\n", firstIFDOffset);	TiffIfd ifd(firstIFDOffset, *inSource, swp);		status_t initcheck;	initcheck = ifd.InitCheck();	printf("Init Check: %d\n",		static_cast<int>(initcheck));			// Read in some fields in order to determine whether or not	// this particular TIFF image is supported by this translator		// Check the required fields	if (initcheck == B_OK) {					bool bAllocArrays = true;		TiffDetails localdetails;		if (!pdetails) {			bAllocArrays = false;			pdetails = &localdetails;		}		status_t result;		result = check_tiff_fields(ifd, pdetails, bAllocArrays);				if (result == B_OK && outInfo) {			outInfo->type = B_TIFF_FORMAT;			outInfo->group = B_TRANSLATOR_BITMAP;			outInfo->quality = TIFF_IN_QUALITY;			outInfo->capability = TIFF_IN_CAPABILITY;			strcpy(outInfo->MIME, "image/tiff");						copy_tiff_name(outInfo->name, pdetails, swp);		}				return result;	}			if (initcheck != B_ERROR && initcheck != B_NO_MEMORY)		// return B_NO_TRANSLATOR if unexpected data was encountered		return B_NO_TRANSLATOR;	else		// return B_ERROR or B_NO_MEMORY		return initcheck;}