Re: [Cegcc-devel] Problem with fileno()

2010-01-01 Thread Pedro Alves
On Monday 06 July 2009 13:06:39, Johnny Willemsen wrote: > Hi, > > > > > int fileno (FILE*); > > > > void *_fileno (FILE*); > > > > > > I think this will not work. > > > > Why? I'm curious; are you using fileno instead of _fileno? > > I missed the _ > > > If you're porting some code to CE that

Re: [Cegcc-devel] Problem with fileno()

2009-07-06 Thread Johnny Willemsen
Hi, > > > int fileno (FILE*); > > > void *_fileno (FILE*); > > > > I think this will not work. > > Why? I'm curious; are you using fileno instead of _fileno? I missed the _ > If you're porting some code to CE that is using the posixy > open/read/write etc. and getting at the file descriptor wi

Re: [Cegcc-devel] Problem with fileno()

2009-07-06 Thread Pedro Alves
On Monday 06 July 2009 07:52:13, Johnny Willemsen wrote: > > int fileno (FILE*); > > void *_fileno (FILE*); > > I think this will not work. Why? I'm curious; are you using fileno instead of _fileno? > If it is easier for other projects, feel free to > convert the method return value type back

Re: [Cegcc-devel] Problem with fileno()

2009-07-06 Thread Pedro Alves
On Monday 06 July 2009 07:52:13, Johnny Willemsen wrote: > > int fileno (FILE*); > > void *_fileno (FILE*); > > I think this will not work. Why? I'm curious; are you using fileno instead of _fileno? > If it is easier for other projects, feel free to > convert the method return value type back

Re: [Cegcc-devel] Problem with fileno()

2009-07-05 Thread Johnny Willemsen
Hi, > > > I'll try changing the definition of fileno to void *, we'll see > what > > > breaks :-) > > > > Compiling live555 now fails on some lines that use fileno(), with: > > > > error: invalid conversion from 'void*' to 'int' > > > > Just saying. > > > > Yes, that was why I made it return an i

Re: [Cegcc-devel] Problem with fileno()

2009-07-05 Thread Pedro Alves
On Wednesday 20 May 2009 14:47:00, Pierre Ynard wrote: > > > I'll try changing the definition of fileno to void *, we'll see what > > breaks :-) > > Compiling live555 now fails on some lines that use fileno(), with: > > error: invalid conversion from 'void*' to 'int' > > Just saying. > Yes, t

Re: [Cegcc-devel] Problem with fileno()

2009-07-05 Thread Pedro Alves
On Wednesday 20 May 2009 14:47:00, Pierre Ynard wrote: > > > I'll try changing the definition of fileno to void *, we'll see what > > breaks :-) > > Compiling live555 now fails on some lines that use fileno(), with: > > error: invalid conversion from 'void*' to 'int' > > Just saying. > Yes, t

Re: [Cegcc-devel] Problem with fileno()

2009-05-20 Thread Pierre Ynard
> I'll try changing the definition of fileno to void *, we'll see what > breaks :-) Compiling live555 now fails on some lines that use fileno(), with: error: invalid conversion from 'void*' to 'int' Just saying. -- Pierre Ynard --

Re: [Cegcc-devel] Problem with fileno()

2009-05-18 Thread Vincent R.
On Mon, 18 May 2009 15:27:57 +0200, Danny Backx wrote: > MSDN is consistent in stating that the return value of _fileno is an > int, but MSDN has been known to be wrong. I have the impression that > this is deliberate in some occasions. Hi, With msvc, fileno is declared like this : _CRTIMP void

Re: [Cegcc-devel] Problem with fileno()

2009-05-18 Thread Danny Backx
MSDN is consistent in stating that the return value of _fileno is an int, but MSDN has been known to be wrong. I have the impression that this is deliberate in some occasions. But Pedro once wrote this : On Wed, 2008-02-13 at 09:06 +, Pedro Alves wrote: > Remember that a file descriptor in Wi

Re: [Cegcc-devel] Problem with fileno()

2009-05-18 Thread Johnny Willemsen
Hi, > Hmm, confusing stuff. Yes, it is ;-) > On http://msdn.microsoft.com/en-us/library/ms860492.aspx you'll find > that _fileno returns an int value. I believe that _fileno and fileno > are > the same, but I may be mistaken. > > MSDN also mentions that _fileno is ISO C++ conformant, and fileno

Re: [Cegcc-devel] Problem with fileno()

2009-05-18 Thread Danny Backx
Hmm, confusing stuff. On http://msdn.microsoft.com/en-us/library/ms860492.aspx you'll find that _fileno returns an int value. I believe that _fileno and fileno are the same, but I may be mistaken. MSDN also mentions that _fileno is ISO C++ conformant, and fileno is deprecated. Our src/mingw/incl