[glib: 7/11] Fix redefinition of local variable in gio/gnetworkservice.c




commit 124733d10c17c27223659f31eb0610e9de42c015
Author: Loic Le Page <llepage fluendo com>
Date:   Wed Jan 19 18:47:38 2022 +0100

    Fix redefinition of local variable in gio/gnetworkservice.c

 gio/gnetworkservice.c | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)
---
diff --git a/gio/gnetworkservice.c b/gio/gnetworkservice.c
index 2b8571e9b..f5ba9d848 100644
--- a/gio/gnetworkservice.c
+++ b/gio/gnetworkservice.c
@@ -445,7 +445,7 @@ g_network_service_address_enumerator_next (GSocketAddressEnumerator  *enumerator
     {
       if (srv_enum->addr_enum == NULL && srv_enum->t)
         {
-          GError *error = NULL;
+          GError *my_error = NULL;
           gchar *uri;
           gchar *hostname;
           GSocketConnectable *addr;
@@ -477,15 +477,15 @@ g_network_service_address_enumerator_next (GSocketAddressEnumerator  *enumerator
 
           addr = g_network_address_parse_uri (uri,
                                               g_srv_target_get_port (target),
-                                              &error);
+                                              &my_error);
           g_free (uri);
 
           if (addr == NULL)
             {
               if (srv_enum->error == NULL)
-                srv_enum->error = error;
+                srv_enum->error = my_error;
               else
-                g_error_free (error);
+                g_error_free (my_error);
               continue;
             }
 
@@ -498,18 +498,18 @@ g_network_service_address_enumerator_next (GSocketAddressEnumerator  *enumerator
 
       if (srv_enum->addr_enum)
         {
-          GError *error = NULL;
+          GError *my_error = NULL;
 
           ret = g_socket_address_enumerator_next (srv_enum->addr_enum,
                                                   cancellable,
-                                                  &error);
+                                                  &my_error);
 
-          if (error)
+          if (my_error)
             {
               if (srv_enum->error == NULL)
-                srv_enum->error = error;
+                srv_enum->error = my_error;
               else
-                g_error_free (error);
+                g_error_free (my_error);
             }
 
           if (!ret)


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