Current-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Change of funopen(3)
In article <20120203.121612.1799630238396262672.taca%back-street.net@localhost>,
Takahiro Kambe <taca%back-street.net@localhost> wrote:
>In message <20120202191632.GO15658%snowdrop.l8s.co.uk@localhost>
> on Thu, 2 Feb 2012 19:16:32 +0000,
> David Laight <david%l8s.co.uk@localhost> wrote:
>> On Thu, Feb 02, 2012 at 03:23:22PM +0900, Takahiro Kambe wrote:
>>> What is the best way to modify (or writing portable) code using
>>> funopen(3) to deal with change of its 4th parameter?
>>>
>>> fpos_t (*seekfn)(void *, fpos_t, int)
>>>
>>> v.s.
>>>
>>> off_t (*seekfn)(void *, off_t, int)
>>
>>
>> Use off_t!
>> The change to seekfn() is to maintain binary compatibility
>> when fpos_t changed to a structure type.
>I know it. But I wondered s/fpos_t/off_t/g cause problem on other
>operating systems.
This cannot be an issue, since fpos_t is an opaque type only known
to the guts of stdio, so it is unknown what a seekfn() function that
has not access to the type info can do with it. This has already been
handled in an ugly way so far, so it cannot get uglier.
christos
Home |
Main Index |
Thread Index |
Old Index