This is the mail archive of the libc-alpha@sources.redhat.com 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]

Re: A patch for elf/dl-version.c


On Fri, Dec 08, 2000 at 09:09:47AM -0800, Ulrich Drepper wrote:
> "H . J . Lu" <hjl@valinux.com> writes:
> 
> > We should check map->l_name[0] for printing.
> 
> OK, I've applied the patch.  Thanks,
> 

Well, looking at the file, there are 3 more places in dl-version.c
where map->l_name is used for printing. You may want to fix those
also.


-- 
H.J. Lu (hjl@valinux.com)
--
--- /work/gnu/import/libc/elf/dl-version.c	Fri Dec  8 09:13:10 2000
+++ ./dl-version.c	Fri Dec  8 09:18:53 2000
@@ -115,7 +115,7 @@ no version information available (requir
 	  char buf[20];
 	  buf[sizeof (buf) - 1] = '\0';
 	  /* XXX We cannot translate the message.  */
-	  _dl_signal_error (0, map->l_name,
+	  _dl_signal_error (0, map->l_name[0] ? map->l_name : _dl_argv[0],
 			    make_string ("unsupported version ",
 					 _itoa_word (def->vd_version,
 						     &buf[sizeof (buf) - 1],
@@ -149,7 +149,7 @@ no version information available (requir
     {
       if (verbose)
 	/* XXX We cannot translate the message.  */
-	_dl_signal_cerror (0, map->l_name,
+	_dl_signal_cerror (0, map->l_name[0] ? map->l_name : _dl_argv[0],
 			   make_string ("weak version `", string,
 					"' not found (required by ", name,
 					")"));
@@ -157,7 +157,7 @@ no version information available (requir
     }
 
   /* XXX We cannot translate the message.  */
-  _dl_signal_cerror (0, map->l_name,
+  _dl_signal_cerror (0, map->l_name[0] ? map->l_name : _dl_argv[0],
 		     make_string ("version `", string,
 				  "' not found (required by ", name, ")"));
   return 1;

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