[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: fcntl.h
Tamminen Eero wrote:
> I noticed that fcntl.h states the smallest gemdos file handle to be
> -3, whereas my MiNT docs say that there are also -4 and -5 for midi
> i/o.
mntlib bugs should be reported to <mintlib@nasim.cube.net>.
> For -mlong the header file comments there to be a sign extension
> bug in the mintlibs (=> smallest handle 0), is this still valid?
This is not a bug, it's a feature: The Fopen system call returns BIOS
handles word negative, but file handles are long words. The sign of
the word should not be extended to the long word.
> Btw. I wonder why there's no program for converting binaries to
> object files. Hexdumping and including binaries seems like waste
> of time and diskspace. The utility would be used somewhat like
> this (without -n/-o arguments the filename would be used):
> bin2obj [-n sample_one] [-o sample_1.o] sample_1.spl
>
> In the source using this object the sample_one could be declared
> extern unsigned char sample_one;
Such a program would be trivial to write, and I'm not sure that it has
never been written before. I believe that a program of this kind
comes with Pure C (of course, it's for the Pure C object file format
which is incompatible with GCC's).
Michael
--
Email: hohmuth@inf.tu-dresden.de
WWW: http://www.inf.tu-dresden.de/~mh1/
- References:
- fcntl.h
- From: Tamminen Eero <t150315@proffa.cc.tut.fi>