Sophie

Sophie

distrib > Fedora > 17 > i386 > media > updates-src > by-pkgid > 6596c02e85d44486d4f303076940d29b > files > 1

gcalctool-6.4.2.1-2.fc17.src.rpm

From e45bc3134f89e75c48360000d2290324b187bdfc Mon Sep 17 00:00:00 2001
From: Robert Ancell <robert.ancell@canonical.com>
Date: Sat, 28 Jul 2012 18:39:52 +0200
Subject: [PATCH] Use g_warning not g_error when unable to parse currency file

---
 src/currency-manager.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/currency-manager.c b/src/currency-manager.c
index 6086b35..8c061b0 100644
--- a/src/currency-manager.c
+++ b/src/currency-manager.c
@@ -490,7 +490,7 @@ load_ecb_rates(CurrencyManager *manager)
     filename = get_ecb_rate_filepath();
     document = xmlReadFile(filename, NULL, 0);
     if (!document)
-        g_error("Couldn't parse ECB rate file %s", filename);
+        g_warning("Couldn't parse ECB rate file %s", filename);
     g_free (filename);
     if (!document)    
         return;
@@ -498,7 +498,7 @@ load_ecb_rates(CurrencyManager *manager)
     xpath_ctx = xmlXPathNewContext(document);
     if (xpath_ctx == NULL) {
         xmlFreeDoc(document);
-        g_error("Couldn't create XPath context");
+        g_warning("Couldn't create XPath context");
         return;
     }
 
@@ -510,7 +510,7 @@ load_ecb_rates(CurrencyManager *manager)
     if (xpath_obj == NULL) {
         xmlXPathFreeContext(xpath_ctx);
         xmlFreeDoc(document);
-        fprintf(stderr, "Couldn't create XPath object\n");
+        g_warning("Couldn't create XPath object");
         return;
     }
     len = (xpath_obj->nodesetval) ? xpath_obj->nodesetval->nodeNr : 0;
-- 
1.8.0