queue.
- This fixes the bug where the dispatcher would sometimes fail to run the
next method and PkSpawn would warn the user with 'timeout already set'.
29 lines
1.0 KiB
Diff
29 lines
1.0 KiB
Diff
commit 95a2dcf78ba0e2ae6262bfae897a16b0e26408c8
|
|
Author: Richard Hughes <richard@hughsie.com>
|
|
Date: Tue Sep 23 11:43:36 2008 +0100
|
|
|
|
bugfix: when we have more than one transaction queued, don't try to run them all at once
|
|
|
|
This bug was never triggered before as we were running each pk_transaction_run in a loop
|
|
and so blocked at this point. Now we are idle_add'ing them, it's possible for all of
|
|
the remaining queue to be dispatched at the same time.
|
|
This fixes the bug where the dispatcher would sometimes fail to run the second method
|
|
and PkSpawn would error out with 'trying to set timeout when already set'.
|
|
|
|
diff --git a/src/pk-transaction-list.c b/src/pk-transaction-list.c
|
|
index d8da409..23bbcf0 100644
|
|
--- a/src/pk-transaction-list.c
|
|
+++ b/src/pk-transaction-list.c
|
|
@@ -293,8 +293,10 @@
|
|
item = (PkTransactionItem *) g_ptr_array_index (tlist->priv->array, i);
|
|
if (item->committed &&
|
|
!item->running &&
|
|
- !item->finished)
|
|
+ !item->finished) {
|
|
pk_transaction_list_run_item (tlist, item);
|
|
+ break;
|
|
+ }
|
|
}
|
|
}
|
|
|