Error text, Print error message, Retrieve file from remote host – HP Integrity NonStop H-Series User Manual
Page 105
![background image](/manuals/397061/105/background.png)
hd
File number.
proxy
1 , this command applies to the proxy connection.
0 , this command applies to the primary connection.
filename
Name of the file to be deleted.
tag
parameter to be used for the GUARDIAN nowait operation initiated by FTPdelete_nw.
The return value is -1 if the routine fails, otherwise the routine is successful. The error number is set
accordingly.
Error Text
The routine FTPerrtext returns the error text associated with the current errno up to the size limit of
the buffer.
#include "ftpexth"
void FTPerrtext(char *buffer, short limit);
buffer
pointer to where the data is returned.
limit
maximum number of bytes that the buffer can hold. If the return list is longer than the limit, the
error number will be set to TRUNCATED and data up to limit size will be returned in the
buffer.
Print Error Message
The routine FTPerrmsg prints the error message text associated with the current error number to
standard output.
#include "ftpexth"
void FTPerrmsg(char *s)
s
text printed preceding the error message.
Return value
none.
Retrieve File From Remote Host
The routines FTPget and FTPget_nw retrieve a file from a remote host.
#include "ftpexth"
short FTPget(short hd, short proxy, char *in,char *out)
short FTPget_nw(short hd, short proxy, char *in,
char *out, long tag)
hd
file number.
proxy
1, this command applies to the proxy connection.
0, this command applies to the primary connection.
API Routines 105