This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch release/2.26/master updated. glibc-2.26-31-g2723344


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, release/2.26/master has been updated
       via  27233446a62ca35ce0b54566279a99a6774d4210 (commit)
      from  905a6129147e7ee80e8918e23efe212433b8cce7 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=27233446a62ca35ce0b54566279a99a6774d4210

commit 27233446a62ca35ce0b54566279a99a6774d4210
Author: Florian Weimer <fweimer@redhat.com>
Date:   Wed Sep 6 15:47:27 2017 +0200

    resolv: __resolv_conf_attach must not free passed conf object [BZ #22096]
    
    (cherry picked from commit a83047308196e3e54716a39dd85c0a08b198d6bd)

diff --git a/ChangeLog b/ChangeLog
index ef2041b..e98a4bb 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2017-09-06  Florian Weimer  <fweimer@redhat.com>
 
+	[BZ #22096]
+	* resolv/resolv_conf.c (__resolv_conf_attach): Do not free conf in
+	case of failure to obtain the global conf object.
+
+2017-09-06  Florian Weimer  <fweimer@redhat.com>
+
 	[BZ #22095]
 	* resolv/res_init.c (res_vinit_1): Avoid memory leak in case of
 	dynarray allocation failure.
diff --git a/NEWS b/NEWS
index 6295927..9bcb176 100644
--- a/NEWS
+++ b/NEWS
@@ -29,6 +29,7 @@ The following bugs are resolved with this release:
   [21941] powerpc: Restrict xssqrtqp operands to Vector Registers
   [21972] assert macro requires operator== (int) for its argument type
   [22095] resolv: Fix memory leak with OOM during resolv.conf parsing
+  [22096] resolv: __resolv_conf_attach must not free passed conf object
 
 Version 2.26
 
diff --git a/resolv/resolv_conf.c b/resolv/resolv_conf.c
index f391d30..e0f296d 100644
--- a/resolv/resolv_conf.c
+++ b/resolv/resolv_conf.c
@@ -600,10 +600,7 @@ __resolv_conf_attach (struct __res_state *resp, struct resolv_conf *conf)
 
   struct resolv_conf_global *global_copy = get_locked_global ();
   if (global_copy == NULL)
-    {
-      free (conf);
-      return false;
-    }
+    return false;
 
   /* Try to find an unused index in the array.  */
   size_t index;

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog            |    6 ++++++
 NEWS                 |    1 +
 resolv/resolv_conf.c |    5 +----
 3 files changed, 8 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]