tumble under BSD

Al Kossow aek at bitsavers.org
Sat Apr 2 11:21:26 CDT 2016



On 4/1/16 12:21 PM, Diane Bruce wrote:

> It's in ports /usr/ports/graphics/tumble
>
> Not sure if it is up to date or not.
>

Thanks. It appears that the stdio that I'm linking against on OS X 
10.9.5 does not keep the file pointers synchronized between the system
and stdio. Tumble opens a file, and handlers for various image file
types read and rewind the magic number trying to figure out what format
the image file is in. In the case of tiff at least (haven't checked 
others) a syscall file descriptor is passed to libtiff. Once it's 
inside, the tiff library reads the magic number with a read syscall and
erroneously gets data 4K into the file, so it never saw the rewind().

http://austin-group-l.opengroup.narkive.com/2RTHr3EB/fseek-3-question-typo-fix

talks about this issue.

Being a Unix greybeard, it took a couple of days staring at it to figure
out what was going on, since I had never run into a system that behaved
this way.

I may try going back to a G5 running 10.5 to see if OS X stdio has 
always behaved this way. Maybe Guy or Camerion Kaiser know, or it may 
have been discussed on macports.





More information about the cctalk mailing list