[gnome-robots/libgames-scores] Fix build
- From: Michael Catanzaro <mcatanzaro src gnome org>
 
- To: commits-list gnome org
 
- Cc: 
 
- Subject: [gnome-robots/libgames-scores] Fix build
 
- Date: Sun, 21 Sep 2014 16:28:16 +0000 (UTC)
 
commit 260de3fb150978fad34e3a075119e19bde85c652
Author: Michael Catanzaro <mcatanzaro gnome org>
Date:   Sun Sep 21 11:27:54 2014 -0500
    Fix build
    
    And miscellaneous cleanups
 src/game.c |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)
---
diff --git a/src/game.c b/src/game.c
index f95074e..21de289 100644
--- a/src/game.c
+++ b/src/game.c
@@ -232,11 +232,16 @@ log_score (gint sc)
   }
 
   if (sc != 0) {
-  //  games_scores_set_category (highscores, sbuf);
     const gchar* key = sbuf;
     const gchar* name = category_name_from_key (key);
+    GError *error = NULL;
     current_cat = games_scores_category_new (key, name);
-    pos = games_scores_context_add_score (highscores, (guint32) sc, current_cat);
+    // FIXME returns a bool, not the position...
+    pos = games_scores_context_add_score (highscores, (guint32) sc, current_cat, &error);
+    if (error != NULL) {
+      g_warning ("Failed to add score: %s", error->message);
+      g_error_free (error);
+    }
   }
   g_free (sbuf);
 
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]