Skip to content
This repository has been archived by the owner on Jul 17, 2024. It is now read-only.

Commit

Permalink
Allow running as libbusybox.so
Browse files Browse the repository at this point in the history
  • Loading branch information
topjohnwu committed May 8, 2021
1 parent c29a868 commit 1213ac5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion libbb/appletlib.c
Original file line number Diff line number Diff line change
Expand Up @@ -1138,7 +1138,10 @@ int main(int argc UNUSED_PARAM, char **argv)
if (argv[1] && is_prefixed_with(bb_basename(argv[0]), "busybox"))
argv++;
# endif
applet_name = argv[0];
if (is_suffixed_with(argv[0], "busybox.so"))
applet_name = "busybox";
else
applet_name = argv[0];
if (applet_name[0] == '-')
applet_name++;
applet_name = bb_basename(applet_name);
Expand Down

0 comments on commit 1213ac5

Please sign in to comment.