Fix string iteration logic in wxFTP::Pwd()

wxString iterators can't be dereferenced once they reach the end of the
string, so compare them with end rather than checking if the value they point
to is non-NUL.

This makes wxFTP::Pwd() actually work, which was apparently broken since quite
some time (perhaps ever since c9f7896861 9+
years ago).

See #17679.

(cherry picked from commit d0c57dbef0)
This commit is contained in:
Vadim Zeitlin
2016-09-25 01:20:41 +02:00
parent 7f6d9166a2
commit d77661c73b
3 changed files with 17 additions and 6 deletions

View File

@@ -587,6 +587,7 @@ All:
- Fix wxFileName::MakeRelativeTo() for directory relatively to itself.
- Fix wxLocale::IsOk() return true even if setting the locale failed.
- Fix wxFTP::Pwd() to actually work.
- Null-terminate wxApp::argv for compatibility with the real argv.
Unix: