in reply to Re: printing fcntl( fd, F_GETFL,0 ) return value changes its representation (usage)
in thread printing fcntl( fd, F_GETFL,0 ) return value changes its representation
However, what causes the call to fail is if I print the value returned from the F_GETFL call$flags = fcntl( FH, F_GETFL, 0 ); $rc = fcntl( FH, F_SETFL, $flags );
I am not sure why the ioctl documentation and fcntl documentation are out of synch, but the third argument is NOT required by the Unix C function; I have verified that, in the absence of the print statement, my call syntax is not the issue. Thanks for your response, feel free to correct my logic as necessary.$flags = fcntl( FH, F_GETFL, 0 ); print "current flags -> $flags\n"; ## now we've got trouble $rc = fcntl( FH, F_SETFL, $flags );
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: printing fcntl( fd, F_GETFL,0 ) return value changes its representation (usage)
by tye (Sage) on Jun 06, 2003 at 19:35 UTC |