pathbar: Setup the cancellable earlier
There have been reports of people hitting the assertion in drop_node_for_cancellable, and a plausible explanation is that we are adding it too late in the codepath. Fixes: #5792
This commit is contained in:
@@ -935,6 +935,7 @@ _gtk_path_bar_set_file (GtkPathBar *path_bar,
|
||||
|
||||
info->cancellable = g_cancellable_new ();
|
||||
path_bar->get_info_cancellable = info->cancellable;
|
||||
add_cancellable (path_bar, info->cancellable);
|
||||
|
||||
if (g_file_is_native (info->file))
|
||||
{
|
||||
@@ -959,7 +960,6 @@ _gtk_path_bar_set_file (GtkPathBar *path_bar,
|
||||
gtk_path_bar_get_mount_callback,
|
||||
info);
|
||||
}
|
||||
add_cancellable (path_bar, info->cancellable);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user