]> sourceware.org Git - glibc.git/commitdiff
Fix error messages in elf/tst-dlmopen1.c.
authorCarlos O'Donell <carlos@systemhalted.org>
Fri, 18 Sep 2015 14:27:55 +0000 (10:27 -0400)
committerCarlos O'Donell <carlos@systemhalted.org>
Fri, 18 Sep 2015 14:27:55 +0000 (10:27 -0400)
The test error messages incorrectly reference LIBC_SO
when they should reference the dlmopen'd library
tst-dlmopen1mod.so. Define TEST_SO and use it in
all the error messages.

ChangeLog
elf/tst-dlmopen1.c

index bb753824093fc69431d4fdede90693d55ad6005d..22c17f5bde88460dfe43525a754f4ba1c1a10997 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2015-09-18  Carlos O'Donell  <carlos@redhat.com>
 
+       * elf/tst-dlmopen1.c: Define TEST_SO.
+       (do_test): Use TEST_SO.
+
        * elf/dl-load.c: Include libc-internal.h.
        (_dl_map_object_from_fd): Use ALIGN_UP and ALIGN_DOWN.
 
index 9839267d8f1d231c36a63ec501e77739b4ad0896..5a05891846545f5a5c260f59ace132dba2562951 100644 (file)
@@ -2,6 +2,7 @@
 #include <stdio.h>
 #include <gnu/lib-names.h>
 
+#define TEST_SO "$ORIGIN/tst-dlmopen1mod.so"
 
 static int
 do_test (void)
@@ -34,7 +35,7 @@ do_test (void)
       return 1;
     }
 
-  h = dlmopen (LM_ID_NEWLM, "$ORIGIN/tst-dlmopen1mod.so", RTLD_LAZY);
+  h = dlmopen (LM_ID_NEWLM, TEST_SO, RTLD_LAZY);
   if (h == NULL)
     {
       printf ("cannot get handle for %s: %s\n",
@@ -52,7 +53,7 @@ do_test (void)
 
   if (ns == LM_ID_BASE)
     {
-      printf ("namespace for %s is LM_ID_BASE\n", LIBC_SO);
+      printf ("namespace for %s is LM_ID_BASE\n", TEST_SO);
       return 1;
     }
 
@@ -69,7 +70,7 @@ do_test (void)
   if (dlclose (h) != 0)
     {
       printf ("dlclose for %s in %s failed: %s\n",
-             LIBC_SO, __func__, dlerror ());
+             TEST_SO, __func__, dlerror ());
       return 1;
     }
 
This page took 0.097493 seconds and 5 git commands to generate.