Return Values

Most functions return a value of -1 to indicate failure and a value of 0 to indicate success. Two functions do not return 0 and -1 values: ftplogoff(), which is of type void, and ftpping(), which returns an error code rather than storing the return value in ftperrno. When the value is -1, the global integer variable ftperrno is set to one of the following codes:

Return Code

FTPSERVICE FTPHOST FTPSOCKET FTPCONNECT FTPLOGIN FTPABORT FTPLOCALFILE FTPDATACONN FTPCOMMAND FTPPROXYTHIRD FTPNOPRIMARY


[Back: File Transfer Protocol API]
[Next: ftpappend()]