00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef __libOftp_Sub_H_proto_
00011 #define __libOftp_Sub_H_proto_
00012
00013
00014 #if 0
00015 #define FTP_DEBUG
00016 #endif
00017
00018
00019
00020 #include <string.h>
00021 #include <errno.h>
00022 #ifdef FTP_DEBUG
00023 #include <stdio.h>
00024 #endif
00025
00026
00027
00028
00029
00030
00031 #ifdef FTP_DEBUG
00032 #define DEBUGPRINT1(f,a1) printf( "(" __FILE__ ") " f,(a1))
00033 #else
00034 #define DEBUGPRINT1(f,a1)
00035 #endif
00036
00037 #define copy_strerror() \
00038 strncpy( ftp->error_message, strerror(errno), sizeof(ftp->error_message)-1 );
00039
00040
00041
00042
00043
00044 #ifdef __cplusplus
00045 extern "C" {
00046 #endif
00047 int sendn( int sd, const char *buf, int len, int flags );
00048 int ftp_send_command( LIBOFTP *ftp, const char *cmd );
00049 int ftp_receive_response( LIBOFTP *ftp, char *res_buf, int bufsiz );
00050 int ftp_getready_active( LIBOFTP *ftp, const char *cmd, const char *fname );
00051 int ftp_getready_pasv( LIBOFTP *ftp, const char *cmd, const char *fname );
00052
00053
00054 #if defined( __QNX__ ) && !defined( __QNXNTO__ )
00055 int snprintf( char *, int, char *, ... );
00056 #endif
00057
00058
00059
00060
00061 #ifdef __cplusplus
00062 }
00063 #endif
00064
00065 #endif