Changing FS type reported by Wine

Tony Lambregts tony_lambregts at telusplanet.net
Mon Dec 23 15:41:01 CST 2002


Duane Clark wrote:

> Stephen Mollett wrote:
>
>>
>> I'm using ReiserFS. I've also tried on a 40GB ext3 filesystem on a 
>> spare drive. The error comes from VirtualDub, which believes that 
>> it's running on a FAT32 filesystem (obviously that's what Wine 
>> reports to any program that asks what FS type a drive is). I've tried 
>> working around it by using vdub's 'segmented AVI' feature (which 
>> creates multiple AVIs <= 2GB) but I can't use these successfully 
>> under Linux.
>
>
> In the file wine/files/drive.c, in the function 
> GetVolumeInformationW() (down around line 1965), is this:
>
>
>     if (fsname && fsname_len)
>     {
>         /* Diablo checks that return code ... */
>         if (DOSDrives[drive].type == DRIVE_CDROM)
>         {
>             static const WCHAR cdfsW[] = {'C','D','F','S',0};
>             strncpyW( fsname, cdfsW, fsname_len );
>         }
>     else
>         {
>             static const WCHAR fatW[] = {'F','A','T',0};
>             strncpyW( fsname, fatW, fsname_len );
>         }
>         fsname[fsname_len - 1] = 0; /* ensure 0 termination */
>     }
>
> That appears to hardcode the filesystem "name" to FAT. You might try 
> changing that to NTFS. That assumes that this is the call your app is 
> using to determine filesystem type.
>
> I assume you have already determined that ReiserFS supports files 
> larger than 2GB?
>
Well thats a patch that shouldn't go into cvs. <g>  If it does "fix" the 
application though then there should be some way for wine to do it the 
"right way".  The way I see it there are two ways to do this.

1.) wine should try to set the fsname to NTFS if underlying file system 
can support files sizes > 4GB.

2.)There should be a conf file option for NTFS along with MSDOS, unix 
and win95.

The difficulty with wine trying to do this automaticly is that it would 
need to find the file system type of the current directory and not the 
root. This is of course because of the way the unix file system works. 
 The current directory could very well be an MSDOS drive while the root 
drive is an ext3 and this function is only aware of the root drive.

AFAICS Having it as a config option is easier to implement and removes 
the problem from the developers hands.<g>

For myself I (think I) could implement it as a config option but Iwould 
prefer that wine could deal with it automaticly.  If anyone has any 
suggestions I would appreciate it.

-- 

Tony Lambregts






More information about the wine-users mailing list