tfFtpLogin

Jump to: navigation, search

Table of Contents >> Application Reference >> FTP Client API


#include <trsocket.h>


int tfFtpLogin (
ttUserFtpHandle ftpUserHandle,
char * userNamePtr,
char * passwordNamePtr,
char * accountNamePtr
);


Function Description

This function attempts to log on and authenticate to the remote FTP server.


Parameters

  • ftpUserHandle
    The FTP session handle.
  • userNamePtr
    A pointer to the username string.
  • passwordNamePtr
    A pointer to the password string.
  • accountNamePtr
    A pointer to the account string (if needed).


Returns

  • TM_ENOERROR
    Success.
  • TM_WOULDBLOCK
    This FTP session is non-blocking and the call did not complete.
  • TM_EACCES
    Previous command did not complete.
  • TM_ENOTCONN
    The user is not currently connected to a FTP server.
  • TM_EINVAL
    Invalid FTP session pointer.
  • TM_FTP_SYNTAXCMD
    Syntax error, command unrecognized.
  • TM_FTP_SERVNAVAIL
    Service not available, closing FTP connection.
  • TM_FTP_NEEDPASS
    User name okay, need password.
  • TM_FTP_NEEDACCTLOGIN
    Need account for login.
  • TM_FTP_BADCMDSEQ
    Bad sequence of commands.


Table of Contents >> Application Reference >> FTP Client API