Fix problem reading some FAT32 partitions (#605175)

This problem was introduced with GParted 0.4.7 when the "-a"
option was removed from the dosfsck command.  The dosfsck command
is used to read the number of used sectors.  Instead we will now
use the "-n" option which does not write any changes to the file
system, and allows non-interactive operation.
This commit is contained in:
Curtis Gedak 2010-01-14 10:47:21 -07:00
parent 89f62578b4
commit 1155fa6dab
2 changed files with 2 additions and 2 deletions

View File

@ -64,7 +64,7 @@ FS fat16::get_filesystem_support()
void fat16::set_used_sectors( Partition & partition )
{
exit_status = Utils::execute_command( "dosfsck -v " + partition .get_path(), output, error, true ) ;
exit_status = Utils::execute_command( "dosfsck -n -v " + partition .get_path(), output, error, true ) ;
if ( exit_status == 0 || exit_status == 1 || exit_status == 256 )
{
//free clusters

View File

@ -64,7 +64,7 @@ FS fat32::get_filesystem_support()
void fat32::set_used_sectors( Partition & partition )
{
//FIXME: i've encoutered a readonly fat32 file system.. this won't work with the -a ... best check also without the -a
exit_status = Utils::execute_command( "dosfsck -v " + partition .get_path(), output, error, true ) ;
exit_status = Utils::execute_command( "dosfsck -n -v " + partition .get_path(), output, error, true ) ;
if ( exit_status == 0 || exit_status == 1 || exit_status == 256 )
{
//free clusters