Ticket #4845 (closed defect: fixed)
wxURL can't download file with a path
|Reported by:||kervala||Owned by:|
In wxURL, m_path member is full of garbage characters so GetInputStream fails.
The first method which returns a bad path is wxURI::ParsePath and inside this method, the code responsible for bad conversion seems to be :
Normalize(theBuffer, true); // line 655 from src/common/uri.cpp
I don't understand the goal of this method so my temporary fix is to not normalize the path.
To reproduce this bug, I simply use :
wxURL data(_T(" http://www.kervala.net/index.htm")); // any URL with a path has the same problem
wxInputStream *input = data.GetInputStream(); // <- crash
Thanks a lot for fixing this.