winecfg: fix drive detection

Michael Jung mjung at iss.tu-darmstadt.de
Fri Feb 11 13:37:17 CST 2005


* winecfg's automatic drive detection crashes if the root directory is not 
mapped to a drive letter. This is due to the fact that a NULL pointer value 
is assigned to add_drive's 'serial' parameter which is then given to strlen 
via strdupA.
* winecfg's strdupA doesn't allocate enough heap memory to hold the 
terminating '\0' character.
* Due to a missing break all previously unmapped drive letters are mapped to 
'/', which results in an error message stating that there is no free drive 
letter to map to '/'.

Changelog:
 Fixed automatic drive detection for the case that the root directory is not 
already mapped
   
Ciao,
-- 
Michael Jung
mjung at iss.tu-darmstadt.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: programs_winecfg_drivedetect_c.diff
Type: text/x-diff
Size: 1527 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20050211/2074ca26/programs_winecfg_drivedetect_c.bin


More information about the wine-patches mailing list