GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
FDCLEAN(3) libdill Library Functions FDCLEAN(3)

fdclean - erases cached info about a file descriptor


#include <libdill.h>
void fdclean(
    int fd);

    

This function drops any state that libdill associates with a file descriptor. It has to be called before the file descriptor is closed. If it is not, the behavior is undefined.

It should also be used whenever you are losing control of the file descriptor. For example, when passing it to a third-party library. Also, if you are handed the file descriptor by third party code you should call this function just before returning it back to the original owner.

fd: file descriptor (OS-level one, not a libdill handle)

None.

None.


int fds[2];
pipe(fds);
use_the_pipe(fds);
fdclean(fds[0]);
close(fds[0]);
fdclean(fds[1]);
close(fds[1]);

    

fdin(3) fdout(3)
libdill

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.