mirror of
https://gitlab.freedesktop.org/libbsd/libbsd.git
synced 2025-05-29 07:25:57 +02:00
Try to check if setproctitle() constructor got passed arguments
This commit is contained in:
parent
6faea4d2a0
commit
50e4c55afd
@ -135,6 +135,10 @@ spt_init(int argc, char *argv[], char *envp[])
|
|||||||
char *base, *end, *nul, *tmp;
|
char *base, *end, *nul, *tmp;
|
||||||
int i, error;
|
int i, error;
|
||||||
|
|
||||||
|
/* Try to make sure we got called with main() arguments. */
|
||||||
|
if (argc < 0)
|
||||||
|
return;
|
||||||
|
|
||||||
base = argv[0];
|
base = argv[0];
|
||||||
if (base == NULL)
|
if (base == NULL)
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user