about summary refs log tree commit diff
path: root/dlfcn
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2000-12-28 00:48:48 +0000
committerUlrich Drepper <drepper@redhat.com>2000-12-28 00:48:48 +0000
commit9c99fa3d310f4652e1f30c9fe7bb69da868b4f46 (patch)
tree1ce7b7b0309145ecf43561de7f08f84bcdb52c69 /dlfcn
parentbb548f63d59de945c244c11e9e5668c3916b477a (diff)
downloadglibc-9c99fa3d310f4652e1f30c9fe7bb69da868b4f46.tar.gz
glibc-9c99fa3d310f4652e1f30c9fe7bb69da868b4f46.tar.xz
glibc-9c99fa3d310f4652e1f30c9fe7bb69da868b4f46.zip
Update.
	* dlfcn/dlerror.c (dlerror): Always create output string which
	includes object file name.
Diffstat (limited to 'dlfcn')
-rw-r--r--dlfcn/dlerror.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/dlfcn/dlerror.c b/dlfcn/dlerror.c
index 929b5f439b..6ce601d05b 100644
--- a/dlfcn/dlerror.c
+++ b/dlfcn/dlerror.c
@@ -69,10 +69,9 @@ dlerror (void)
   else
     {
       buf = (char *) result->errstring;
-      if (result->errcode != 0
-	  && __asprintf (&buf, "%s: %s: %s",
-			 result->objname, _(result->errstring),
-			 strerror (result->errcode)) != -1)
+      if (__asprintf (&buf, result->errcode != 0 ? "%s: %s: %s" : "%s: %s",
+		      result->objname, _(result->errstring),
+		      strerror (result->errcode)) != -1)
 	{
 	  /* We don't need the error string anymore.  */
 	  if (strcmp (result->errstring, "out of memory") != 0)