Ulrich Eckhardt wrote:
> Devika wrote:
>>I want to call fcntl function for which I need fd(). The code
>>part is smthing like :
>>ofstream osf("somefile" , ios::app);
>>filebuf * fb ;
>>fb = osf.rdbuf();
>>fcntl(fb -> fd(), F_SETLKW, &cfLock);
>>Now this code was working fine with gcc 2.96 but now it[gcc
>>3.2.3] says no matching function for fd() since the function
>>fd() of basic_filebuf has been removed in gcc 3.2.3. and they
>>have provided new extension stdio_filebuf.
> 1. http://gcc.gnu.org/gcc-2.96.html
> 2. access to underlying filedescriptors was never part of C++
> iostreams, although GCC's C++ stdlibrary provided means for
> that.
That's not really true. Access to underlying file descriptors
was part of the original classical iostream. The standard
didn't endorse it because not all systems have such a thing, but
it seems obvious that no serious compiler purveyor will want to
break existing code, especially when such code was compatible
with the previous existing practice.
--
James Kanze mailto: [EMAIL PROTECTED]
Conseils en informatique orient�e objet/
Beratung in objektorientierter Datenverarbeitung
9 pl. Pierre S�mard, 78210 St.-Cyr-l'�cole, France +33 (0)1 30 23 00 34
_______________________________________________
Help-gplusplus mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gplusplus