File A0008-Silence-compiler-warnings-about-shadowing-global-declarations.patch of Package libplist.4095

From b3cbcc256ab1f034dc3122517aab1be2a9d932e6 Mon Sep 17 00:00:00 2001
From: Nikias Bassen <nikias@gmx.li>
Date: Sun, 18 May 2014 03:25:58 +0200
Subject: [PATCH] xplist: Silence compiler warnings about shadowing global
 declarations

---
 src/xplist.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/xplist.c b/src/xplist.c
index 405a844..62c624e 100644
--- a/src/xplist.c
+++ b/src/xplist.c
@@ -136,11 +136,11 @@ static struct node_t* new_key_node(const char* name)
     return node_create(NULL, data);
 }
 
-static struct node_t* new_uint_node(uint64_t uint)
+static struct node_t* new_uint_node(uint64_t value)
 {
     plist_data_t data = plist_new_plist_data();
     data->type = PLIST_UINT;
-    data->intval = uint;
+    data->intval = value;
     data->length = sizeof(uint64_t);
     return node_create(NULL, data);
 }
@@ -222,8 +222,8 @@ static void node_to_xml(node_t* node, void *xml_struct)
     case PLIST_DATE:
         tag = XPLIST_DATE;
         {
-            time_t time = (time_t)node_data->timeval.tv_sec;
-            struct tm *btime = gmtime(&time);
+            time_t timev = (time_t)node_data->timeval.tv_sec;
+            struct tm *btime = gmtime(&timev);
             if (btime) {
                 val = (char*)malloc(24);
                 memset(val, 0, 24);
@@ -395,14 +395,14 @@ static void xml_to_node(xmlNodePtr xml_node, plist_t * plist_node)
         if (!xmlStrcmp(node->name, XPLIST_DATE))
         {
             xmlChar *strval = xmlNodeGetContent(node);
-            time_t time = 0;
+            time_t timev = 0;
             if (strlen((const char*)strval) >= 11) {
                 struct tm btime;
                 struct tm* tm_utc;
                 parse_date((const char*)strval, &btime);
-                time = mktime(&btime);
-                tm_utc = gmtime(&time);
-                time -= (mktime(tm_utc) - time);
+                timev = mktime(&btime);
+                tm_utc = gmtime(&timev);
+                timev -= (mktime(tm_utc) - timev);
             }
             data->timeval.tv_sec = (long)time;
             data->timeval.tv_usec = 0;
openSUSE Build Service is sponsored by