FTP client library for mbed-os
Revision 2:88b7399c8260, committed 2020-02-28
- Comitter:
- dkato
- Date:
- Fri Feb 28 00:17:00 2020 +0000
- Parent:
- 1:e069c405c934
- Commit message:
- Added switch to binary mode
Changed in this revision
FTPClient.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r e069c405c934 -r 88b7399c8260 FTPClient.cpp --- a/FTPClient.cpp Tue Sep 18 08:01:30 2018 +0000 +++ b/FTPClient.cpp Fri Feb 28 00:17:00 2020 +0000 @@ -82,6 +82,14 @@ ftp_debug_print("ERROR: %s(%d)\r\n", __FILE__, __LINE__); return false; } + + sprintf(p_ftp_buf, "type I\r\n"); + FTPClientControlSock.send(p_ftp_buf, strlen(p_ftp_buf)); + if (FTPClientControlSock.recv(p_ftp_buf, FTP_BUF_SIZE) <= 0) { + ftp_debug_print("ERROR: %s(%d)\r\n", __FILE__, __LINE__); + return false; + } + _login = true; return true; }