Commit 09064680 authored by Steve Langasek's avatar Steve Langasek
Browse files

Take care to only mark filesystems 'mounted' once the mounted event has been

processed, and don't emit a 'mounted' event if there's already a pending
event in process since this can only mean the mount has already happened
parent a40d941f
......@@ -1468,10 +1468,6 @@ mounted (Mount *mnt)
nih_debug ("%s", MOUNT_NAME (mnt));
mnt->mounted = TRUE;
newly_mounted = TRUE;
nih_main_loop_interrupt ();
mnt->error = ERROR_NONE;
plymouth_update (FALSE);
......@@ -1511,7 +1507,8 @@ mounted (Mount *mnt)
}
}
emit_event ("mounted", mnt, mounted_event_handled);
if (!mnt->pending_call)
emit_event ("mounted", mnt, mounted_event_handled);
fsck_update ();
}
......@@ -1903,6 +1900,10 @@ mounted_event_handled (void *data,
* the current one before we do. */
mnt->pending_call = NULL;
mnt->mounted = TRUE;
newly_mounted = TRUE;
nih_main_loop_interrupt ();
if (!strcmp(mnt->type, "swap")) {
nih_info ("mounted event handled for swap %s", mnt->device);
} else {
......
Markdown is supported
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