Use %m, not strerror, and strerror(err) was broken anyways and should have been
authorEric Andersen <andersen@codepoet.org>
Mon, 30 Sep 2002 20:20:20 +0000 (20:20 -0000)
committerEric Andersen <andersen@codepoet.org>
Mon, 30 Sep 2002 20:20:20 +0000 (20:20 -0000)
strerror(errno).  Problem noted by Alexey V. Neyman <alex.neyman@auriga.ru>

shell/lash.c

index 5c4e97f4aa47c083a81db4433514b44a6290b955..e4654071da8d3dfcb9fcc83d5f62c67be9367382 100644 (file)
@@ -1261,7 +1261,7 @@ static int pseudo_exec(struct child_prog *child)
 
        /* Do not use perror_msg_and_die() here, since we must not 
         * call exit() but should call _exit() instead */
-       fprintf(stderr, "%s: %s\n", child->argv[0], strerror(err));
+       fprintf(stderr, "%s: %m\n", child->argv[0]);
        _exit(EXIT_FAILURE);
 }