NAME | SYNOPSIS | API RESTRICTIONS | DESCRIPTION | NOTE | ATTRIBUTES
$(OS_DIR)/lib/libftpd.a #include <arpa/ftpd/ftpd.h>void ftpdOob(FtpConn *conn);
The function or functions documented here may not be used safely in all application contexts with all APIs provided in the ChorusOS 5.0 product.
See API(5FEA) for details.
This function checks for exceptional conditions on the control connection. An exceptional condition is either an ABORT request sent by the client, or the closure of the control connection by the client.
Although it is not mandatory to call ftpdOob, application routines that perform lengthy operations should call it from time to time. Typically, a file transfer routine should call it between each block read from or written to a file. The consequence of not calling it is that ABORT commands are processed only when the ongoing transfer is finished.
Only the following functions can call ftpdOob: systemSendAscii, systemSendBin, systemReceiveBin, systemReceiveAscii and systemListFiles.
Calling ftpdOob can cause the flow of control to longjmp(3STDC) out of a current routine, affecting the global state. To cleanup the global state, the following function call is performed automatically, prior to the longjump.
*(conn->cleanup)(conn)
To ensure that the cleanup task is run correctly:
The routine that calls ftpdOob must ensure that conn->cleanup points to the correct cleanup routine, prior to calling ftpdOob.
Any information required for the cleanup task must be stored in the connection structure, ftpConn. This structure can be extended by the application to accommodate the information.
If no cleanup routine is required, conn->cleanup must be set to NULL.
As ftpdOob is called explicitly by the application, the application does not need to keep the connection ready for cleanup all of the time; it needs to be ready for cleanup only when ftpdOob is called.
See attributes(5) for descriptions of the following attributes:
ATTRIBUTE TYPE | ATTRIBUTE VALUE |
---|---|
Interface Stability | Evolving |
NAME | SYNOPSIS | API RESTRICTIONS | DESCRIPTION | NOTE | ATTRIBUTES