-
Notifications
You must be signed in to change notification settings - Fork 199
Description
First of all: Thanks for writing a library that works with an FTP server and is easy to use!
I created a new app in Xcode 10 with Swift 5 and the latest version of BlueSocket (installed via CocoaPod) to test it and I've come across a problem:
I can open a normal and a data socket to the FTP server and log in using cmdsocket.write(from: "USER \(username)\r\n") just fine (you can find a list of ftp codes here) but
try cmdSocket.write(from: "LIST\r\n")
let answer = try dataSocket.readString(true)
print(\(answer))
which should list the files and folders at the root only prints the very first one. It's working with a different server (e.g. "speedtest.tele2.net" is free to use for testing), so it looks like "my" server is too slow and/or the library is too fast (and possibly not waiting until the server is done?).
Is there a way to set some kind of timeout for that, e.g. if you don't get a result for the third time, stop reading, instead of stopping after the first try?