[gnome-packagekit/gnome-2-30] Fix an important bug that stopped GetUpdates from working correctly. Fixes rh#615099



commit 5bdf88a6934c5890b83bf7b2d8a857254a913715
Author: Richard Hughes <richard hughsie com>
Date:   Tue Jul 20 08:49:32 2010 +0100

    Fix an important bug that stopped GetUpdates from working correctly. Fixes rh#615099
    
    We were sending an enum, when we should have been sending a bitfield.
    All the time that PK_FILTER_ENUM_NONE was index zero this was no
    problem, and it masked the bug. But when PK_FILTER_ENUM_UNKNOWN pushed
    'none' into second spot in the enum list this caused a client side failure

 src/gpk-check-update.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/gpk-check-update.c b/src/gpk-check-update.c
index 1c8f2c8..391d760 100644
--- a/src/gpk-check-update.c
+++ b/src/gpk-check-update.c
@@ -1095,7 +1095,9 @@ gpk_check_update_query_updates (GpkCheckUpdate *cupdate)
 	}
 
 	/* get new update list */
-	pk_client_get_updates_async (PK_CLIENT(cupdate->priv->task), PK_FILTER_ENUM_NONE, cupdate->priv->cancellable, NULL, NULL,
+	pk_client_get_updates_async (PK_CLIENT(cupdate->priv->task),
+				     pk_bitfield_value (PK_FILTER_ENUM_NONE),
+				     cupdate->priv->cancellable, NULL, NULL,
 				     (GAsyncReadyCallback) gpk_check_update_get_updates_finished_cb, cupdate);
 out:
 	return;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]