Move the xfs_db -r flag to the start when reading XFS usage

I completely missed that when reading XFS file system size and usage it
was using the '-r' read-only flag to xfs_db because it was at the end of
the string on the following line of code.  Move it to the start of the
xfs_db command line, like it is when reading the file system label.
This commit is contained in:
Mike Fleetwood 2018-05-19 09:40:19 +01:00 committed by Curtis Gedak
parent eab54260a4
commit 32df1de163
1 changed files with 2 additions and 2 deletions

View File

@ -88,8 +88,8 @@ FS xfs::get_filesystem_support()
void xfs::set_used_sectors( Partition & partition ) void xfs::set_used_sectors( Partition & partition )
{ {
if ( ! Utils::execute_command( "xfs_db -c 'sb 0' -c 'print blocksize' -c 'print dblocks'" if ( ! Utils::execute_command( "xfs_db -r -c 'sb 0' -c 'print blocksize' -c 'print dblocks'"
" -c 'print fdblocks' -r " + Glib::shell_quote( partition.get_path() ), " -c 'print fdblocks' " + Glib::shell_quote( partition.get_path() ),
output, error, true ) ) output, error, true ) )
{ {
//blocksize //blocksize