X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/64c288fa47480385ad656ae3249b5b131340c1d6..c4709ea55c2299c61ecda2ac350370f656de16ca:/src/generic/dirctrlg.cpp diff --git a/src/generic/dirctrlg.cpp b/src/generic/dirctrlg.cpp index 241acd6eb3..b631aa69cd 100644 --- a/src/generic/dirctrlg.cpp +++ b/src/generic/dirctrlg.cpp @@ -118,12 +118,13 @@ size_t wxGetAvailableDrives(wxArrayString &paths, wxArrayString &names, wxArrayI name.Printf(wxT("%c:"), driveBuffer[i]); #if !defined(__WXWINCE__) - wxChar pname[52]; - if (GetVolumeInformation( path.c_str(), pname, 52, NULL, NULL, NULL, NULL, NULL )) + wxChar pname[52]; // FIXME: why 52 and not MAX_PATH or whatever? + if ( GetVolumeInformation(path, pname, WXSIZEOF(pname), + NULL, NULL, NULL, NULL, 0) ) { - name.Printf(wxT("%s %s"), (const wxChar*) name, pname ); + name << _T(' ') << pname; } -#endif +#endif // __WXWINCE__ int imageId; int driveType = ::GetDriveType(path);