embeddedmz / ftpclient-cpp

C++ client for making FTP requests
MIT License
211 stars 67 forks source link

Fix protocol parsing #46

Closed EugeneSakun closed 1 year ago

EugeneSakun commented 1 year ago

There is a bug in the protocol parsing code that makes it incorrectly recognize protocols in URIs that actually don't have any protocol specified, but start with "ftp", "sftp" etc. For example, "ftp.company.com" will be handled incorrectly.

The fix is trivial: a protocol always ends with a semicolon (ftp:, sftp: etc).

embeddedmz commented 1 year ago

Thank you for your pull request.