glibc/glibc-nscd-hconf.diff
Tomáš Chvátal 5b108142b5 Accepting request 186878 from Base:System
- Update to glibc 2.18 release
  * No source change
- strcoll-overflow.patch: fix buffer overflow in strcoll (CVE-2012-4412,
  bnc#779320)
- readdir_r-overflow.patch: fix readdir_r with long file names
  (CVE-2013-4237, bnc#834594) (forwarded request 186872 from Andreas_Schwab)

OBS-URL: https://build.opensuse.org/request/show/186878
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/glibc?expand=0&rev=153
2013-08-13 09:36:50 +00:00

39 lines
1.1 KiB
Diff

See:
http://sourceware.org/bugzilla/show_bug.cgi?id=11928
Index: glibc-2.17.90/nscd/aicache.c
===================================================================
--- glibc-2.17.90.orig/nscd/aicache.c
+++ glibc-2.17.90/nscd/aicache.c
@@ -25,6 +25,7 @@
#include <time.h>
#include <unistd.h>
#include <sys/mman.h>
+#include <resolv/res_hconf.h>
#include "dbg_log.h"
#include "nscd.h"
@@ -102,6 +103,8 @@ addhstaiX (struct database_dyn *db, int
if (__res_maybe_init (&_res, 0) == -1)
no_more = 1;
+ if (!_res_hconf.initialized)
+ _res_hconf_init ();
/* If we are looking for both IPv4 and IPv6 address we don't want
the lookup functions to automatically promote IPv4 addresses to
Index: glibc-2.17.90/resolv/res_hconf.c
===================================================================
--- glibc-2.17.90.orig/resolv/res_hconf.c
+++ glibc-2.17.90/resolv/res_hconf.c
@@ -81,7 +81,9 @@ static const struct cmd
};
/* Structure containing the state. */
+#ifndef NOT_IN_libc
struct hconf _res_hconf;
+#endif
/* Skip white space. */
static const char *