You can't move "fclose ( f ); f = NULL;" just after "ret = curl_download_get_url" because the "f" FILE pointer is used in options->check_file(f) and fclose ( f ) so if you do so you will break everything.
If you want to do something cleaner, you should put "fclose ( f ); f = NULL;" before the "if(failure)" and remove "fclose ( f ); f = NULL;" inside the "if(failure) Mathieu 2010/4/27 Guilhem BONNEFILLE <guilhem.bonnefi...@gmail.com>: > Concerning this bug, I also noticed that we have to add file extensions. > I will try to add this feature ASAP. > > Concerning your patch, I suggest to move "fclose ( f ); f = NULL;" just > after "ret = curl_download_get_url". IMHO, this opened file is no more > necessary since the curl_download_get_url call is done. Can you confirm > such change still solves the Windows bug? > > If you think it is much simpler to understand with a new bug, feel free > to open it. > > Le jeudi 22 avril 2010 à 15:24 +0200, Mathieu Albinet a écrit : >> hi, >> >> Here is a patch to the bug "2977752 : win-gtk: osm tiles don't show >> up(because of file extension?)". >> It's a Windows specific bug (should I say glib specific behaviour on Windows) >> >> The bug description also indicates a problem with flushing the map cache. >> It's certainly the same kind of problem (glib on Windows). Maybe a new >> bug should be opened to before closing n°2977752. >> >> Mathieu >> ------------------------------------------------------------------------------ >> _______________________________________________ >> Viking-devel mailing list >> Viking-devel@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/viking-devel >> Viking home page: http://viking.sf.net/ > > > ------------------------------------------------------------------------------ _______________________________________________ Viking-devel mailing list Viking-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/viking-devel Viking home page: http://viking.sf.net/