summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--FTPClient.cpp2
-rw-r--r--FTPCommon.cpp4
-rw-r--r--examples/FTPClientSample/FTPClientSample.ino4
-rw-r--r--examples/FTPServerSample/LittleFSSample/LittleFSSample.ino5
4 files changed, 8 insertions, 7 deletions
diff --git a/FTPClient.cpp b/FTPClient.cpp
index d385c43..51456f9 100644
--- a/FTPClient.cpp
+++ b/FTPClient.cpp
@@ -214,7 +214,7 @@ int8_t FTPClient::controlConnect()
FTP_DEBUG_MSG("Ignoring CA verification - FTP only");
}
control.connect(_server->servername.c_str(), _server->port);
- FTP_DEBUG_MSG("Connection to %s:%d ... %S", _server->servername.c_str(), _server->port, control.connected() ? PSTR("OK") : PSTR("failed"));
+ FTP_DEBUG_MSG("Connection to %s:%d ... %s", _server->servername.c_str(), _server->port, control.connected() ? PSTR("OK") : PSTR("failed"));
if (control.connected())
return 1;
return -1;
diff --git a/FTPCommon.cpp b/FTPCommon.cpp
index 0651022..de5838e 100644
--- a/FTPCommon.cpp
+++ b/FTPCommon.cpp
@@ -143,7 +143,7 @@ bool FTPCommon::doNetworkToFile()
void FTPCommon::closeTransfer()
{
- freeBuffer();
- file.close();
data.stop();
+ file.close();
+ freeBuffer();
}
diff --git a/examples/FTPClientSample/FTPClientSample.ino b/examples/FTPClientSample/FTPClientSample.ino
index c456d11..407a798 100644
--- a/examples/FTPClientSample/FTPClientSample.ino
+++ b/examples/FTPClientSample/FTPClientSample.ino
@@ -35,7 +35,7 @@ void setup(void)
WiFi.begin(ssid, password);
bool fsok = LittleFS.begin();
- Serial.printf_P(PSTR("FS init: %S\n"), fsok ? PSTR("ok") : PSTR("fail!"));
+ Serial.printf_P(PSTR("FS init: %s\n"), fsok ? PSTR("ok") : PSTR("fail!"));
// Wait for connection
while (WiFi.status() != WL_CONNECTED)
@@ -43,7 +43,7 @@ void setup(void)
delay(500);
Serial.printf_P(PSTR("."));
}
- Serial.printf_P(PSTR("\nConnected to %S, IP address is %s\n"), ssid, WiFi.localIP().toString().c_str());
+ Serial.printf_P(PSTR("\nConnected to %s, IP address is %s\n"), ssid, WiFi.localIP().toString().c_str());
ftpClient.begin(ftpServerInfo);
}
diff --git a/examples/FTPServerSample/LittleFSSample/LittleFSSample.ino b/examples/FTPServerSample/LittleFSSample/LittleFSSample.ino
index 4a02754..dcb9d6d 100644
--- a/examples/FTPServerSample/LittleFSSample/LittleFSSample.ino
+++ b/examples/FTPServerSample/LittleFSSample/LittleFSSample.ino
@@ -36,7 +36,7 @@ void setup(void)
WiFi.begin(ssid, password);
bool fsok = LittleFS.begin();
- Serial.printf_P(PSTR("FS init: %S\n"), fsok ? PSTR("ok") : PSTR("fail!"));
+ Serial.printf_P(PSTR("FS init: %s\n"), fsok ? PSTR("ok") : PSTR("fail!"));
// Wait for connection
while (WiFi.status() != WL_CONNECTED)
@@ -44,7 +44,7 @@ void setup(void)
delay(500);
Serial.printf_P(PSTR("."));
}
- Serial.printf_P(PSTR("\nConnected to %S, IP address is %s\n"), ssid, WiFi.localIP().toString().c_str());
+ Serial.printf_P(PSTR("\nConnected to %s, IP address is %s\n"), ssid, WiFi.localIP().toString().c_str());
// setup the ftp server with username and password
// ports are defined in FTPCommon.h, default is
@@ -61,6 +61,7 @@ enum consoleaction
list
};
consoleaction action = show;
+uint16_t listDir(String indent, String path);
void loop(void)
{