diff options
author | Ron Yorston <rmy@pobox.com> | 2018-04-04 19:55:09 +0100 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2018-04-04 19:55:09 +0100 |
commit | 33a914da6bba61e27aee82675276bf1dccc52966 (patch) | |
tree | 2242719bf4bb7705504967d54d137d6fe19cc8f3 /include | |
parent | 016ca978455df7257a92236bbfb0c67de4a4bcd8 (diff) | |
download | busybox-w32-33a914da6bba61e27aee82675276bf1dccc52966.tar.gz busybox-w32-33a914da6bba61e27aee82675276bf1dccc52966.tar.bz2 busybox-w32-33a914da6bba61e27aee82675276bf1dccc52966.zip |
ps: obtain applet names from other BusyBox processes
Remove the code which passed applet names to child processes using
environment variables. This only allowed ps to display names for
its ancestors.
Instead attempt to read applet names from the memory of unrelated
processes.
The Microsoft documentation alone wasn't enough to figure out how
to do this. Additional hints from:
https://stackoverflow.com/questions/4298331/exe-or-dll-image-base-address
https://stackoverflow.com/questions/14467229/get-base-address-of-process
Diffstat (limited to 'include')
-rw-r--r-- | include/libbb.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/libbb.h b/include/libbb.h index da3459224..d948f88f3 100644 --- a/include/libbb.h +++ b/include/libbb.h | |||
@@ -2075,7 +2075,7 @@ extern const char bb_path_wtmp_file[] ALIGN1; | |||
2075 | #define bb_dev_null "/dev/null" | 2075 | #define bb_dev_null "/dev/null" |
2076 | #if ENABLE_PLATFORM_MINGW32 | 2076 | #if ENABLE_PLATFORM_MINGW32 |
2077 | #define bb_busybox_exec_path get_busybox_exec_path() | 2077 | #define bb_busybox_exec_path get_busybox_exec_path() |
2078 | extern char *bb_applet_pid(void); | 2078 | extern char bb_applet_name[]; |
2079 | #else | 2079 | #else |
2080 | extern const char bb_busybox_exec_path[] ALIGN1; | 2080 | extern const char bb_busybox_exec_path[] ALIGN1; |
2081 | #endif | 2081 | #endif |