Job Management Partner 1/File Transmission Server/FTP Description, Reference and Operator's Guide

[Contents][Index][Back][Next]


fts_ftp_syn_request_ex() - register transmission requests (synchronous)

Format

#include <apihead.h>
#include <winsock.h>
 
BOOL  fts_ftp_syn_request_ex( SOCKET sock,
                    const char *cardname,
                    FTS_FTP_API_DATA_EX *data,
                    FTS_FTP_API_RETDATA_EX *retdata )

Function

This function registers a transmission request to JP1/FTP and returns the termination result when the transmission is terminated. You can specify the details for the transmission request by specifying a transmission information structure or the name of a registered transmission card. The termination result is returned to the transmission-end information structure. You can determine whether the transmission was successful by checking the trans_status member of the transmission-end information structure.

Arguments

sock

Specifies the return value of fts_ftp_open().

cardname

Specifies the name of a registered transmission card. The file transmission request is registered in accordance with the information on the transmission card.

data

Specifies the address of a transmission information structure.

If NULL is specified in cardname, the file transmission request is registered according to the information specified in data.

If the name of a registered transmission card is specified in cardname, the file transmission request is registered according to the information on the transmission card.

retdata

Specifies the address of a transmission-end information structure. It returns the termination result of transmission.

Notes

Return values

TRUE Normal
FALSE Abnormal.
Registration of the transmission request or acquisition of the transmission termination result failed.

To obtain extended error information, call the WSAGetLastError function. The table below lists and describes the return values for the extended error information. For details about other errors, see the winsock documentation.

Return value of extended error information
(hexadecimal, decimal)
Description Can be retried?
FTS_API_ERROR_NOTSTARTUP
(0x2FFFFF00, 805306112)
WSAStartup() has not been called. No
FTS_API_ERROR_DISCONNECT
(0x2FFFFF05, 805306117)
A connection with the JP1/File Transmission Server/FTP Client service was released. If you want to register the transmission request again, you must start the process over from ftp_ftp_open(). No
FTS_API_ERROR_NOTREADCARD
(0x2FFFFF06, 805306118)
The specified card name cannot be referenced. The card might not have been registered correctly. No
FTS_API_ERROR_BADFORMAT
(0x2FFFFF07, 805306119)
An address with an invalid data type was specified in an argument. No
FTS_API_ERROR_MAXPALTRANS
(0x2FFFFF08, 805306120)
The maximum number of concurrent transmissions has been reached. Register the transmission request after another transmission is finished. Yes
FTS_API_ERROR_MEMORY
(0x2FFFFF0B, 805306123)
Memory allocation failed. No
FTS_API_ERROR_NOTSOCK
(0x2FFFFF0D, 805306125)
The return value of fts_ftp_open() might not have been set in the first argument. No
FTS_API_ERROR_LOGIC
(0x2FFFFF10, 805306128)
A logical conflict error occurred in API. No

[Contents][Back][Next]


[Trademarks]

All Rights Reserved. Copyright (C) 2010, Hitachi, Ltd.