1 # DP: Make it so that a missing /etc/ld.so.conf does not cause an error
2 # DP: message, unless --verbose is enabled. This keeps the debian
3 # DP: installer from barfing during bootstrap of the system.
5 # DP: Updated by gotom, the previous one seems being wrong because it supresses
6 # DP: _all_ warnings about "can't open configuration file". otoh, I introduce
7 # DP: newer patches. it should be checked using chroot and should be contacted
9 # DP: Date: (Updated 2005-01-02 gotom)
12 #--- elf/ldconfig.c 2003-07-08 23:26:27.000000000 +0900
13 #+++ elf/ldconfig.c.debian 2003-07-08 23:29:43.000000000 +0900
14 #@@ -920,26 +920,24 @@
19 #+ const char *canon = filename;
25 # canon = chroot_canon (opt_chroot, filename);
27 #- file = fopen (canon, "r");
35 #- file = fopen (filename, "r");
38 #+ if ((file_fd = open(canon, O_RDONLY | O_EXCL, 0022)) != -1)
39 #+ file = fdopen (file_fd, "r");
43 #- error (0, errno, _("Can't open configuration file %s"), canon);
45 #+ error (0, errno, _("Can't open configuration file %s"), canon);
46 # if (canon != filename)
47 # free ((char *) canon);
50 2004-10-25 GOTO Masanori <gotom@debian.or.jp>
52 * elf/ldconfig.c: Don't print error when default ld.so.conf
56 elf/ldconfig.c | 3 ++-
57 1 file changed, 2 insertions(+), 1 deletion(-)
65 - error (0, errno, _("Can't open configuration file %s"), canon);
66 + if (strcmp(canon, LD_SO_CONF) != 0 || opt_verbose)
67 + error (0, errno, _("Can't open configuration file %s"), canon);
68 if (canon != filename)
69 free ((char *) canon);