Skip to content
Commit bf86fd3f authored by Curtis Gedak's avatar Curtis Gedak
Browse files

Work around: retry ped_disk_commit_to_os() after sleep(1) (#604298)

Bug #604298 involves a problem that can occur when GParted uses
libparted to manipulate a partition table, but the
ped_disk_commit_to_os() function fails to inform the Linux kernel of
these changes to the partition table.  This problem is intermittent in
nature and is difficult to reliably reproduce.

This change is an attempt at a work around.  If the first call to
ped_disk_commit_to_os() fails, then we sleep for 1 second to allow the
system to settle before invoking the function call again.  My testing
has shown that this greatly improves the chances of successfully
informing the kernel of partition changes.

Thanks go to François Dupoux and Steven Shiau for their suggestions
and help to resolve this problem.
parent 9c2d70e1
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment