• FtpLib upload class

    char usrpasswd[256]; sprintf(usrpasswd, "%s:%s", user, password); FILE *file = fopen(localpath, "rb"); if (file == NULL) { perror(NULL); return FTP_LOCALFILE_NOTACCESS; } CURLcode resCode = FtpUpload(remotepath, usrpasswd,file); if (resCode == CURLE_OK){ return FTP_OK; } else { char errorMsg[1023]; sprintf(errorMsg, "%s/n", curl_easy_strerror(resCode)); if (resCode == CURLE_LOGIN_DENIED){ return FTP_LOGIN_DENIED; } else if (resCode == CURLE_COULDNT_CONNECT){ return FTP_COULDNT_CONNECT; } return FTP_FAIL; }

    0
    107
    9KB
    2016-08-22
    10
  • inttypes.h

    inttypes.h

    4
    664
    7KB
    2016-03-26
    50
  • 笔耕不辍

    累计1年每年原创文章数量>=20篇
  • 持续创作

    授予每个自然月内发布4篇或4篇以上原创或翻译IT博文的用户。不积跬步无以至千里,不积小流无以成江海,程序人生的精彩需要坚持不懈地积累!
关注 私信
上传资源赚积分or赚钱