busybox: fix "<applet>: applet not found" message
authorDenis Vlasenko <vda.linux@googlemail.com>
Mon, 9 Apr 2007 03:29:43 +0000 (03:29 -0000)
committerDenis Vlasenko <vda.linux@googlemail.com>
Mon, 9 Apr 2007 03:29:43 +0000 (03:29 -0000)
applets/applets.c

index c8e85cdb1c5f0ca5a960e87f0f13ef080d0ac060..db4ee482e0f247b84d81b271ccbb4008d0deeb17 100644 (file)
@@ -591,7 +591,11 @@ static int busybox_main(int argc, char **argv)
                        puts("\n");
                        return 0;
                }
-       } else run_applet_by_name(argv[1], argc - 1, argv + 1);
+       } else {
+               /* we want "<argv[1]>: applet not found", not "busybox: ..." */
+               applet_name = argv[1];
+               run_applet_by_name(argv[1], argc - 1, argv + 1);
+       }
 
        bb_error_msg_and_die("applet not found");
 }