X-Git-Url: https://pd.if.org/git/?p=startuptools;a=blobdiff_plain;f=exec.c;fp=exec.c;h=bd07905b57dfad9eea220d09565a4ed0fcde053f;hp=b8378cec0430ecf36cfa394f010a2609195a0410;hb=b649ad438108ea1865c05a155cd4b47a9eb7efe4;hpb=a3fb8f7fdef8cf61b194fd8b44b5c9c39923ffed diff --git a/exec.c b/exec.c index b8378ce..bd07905 100644 --- a/exec.c +++ b/exec.c @@ -15,6 +15,11 @@ static void do_exec(int skip, int ac, char *av[]) { int i; + if (skip >= ac) { + fprintf(stderr, "nothing to exec\n"); + exit(EXIT_FAILURE); + } + for (i=0;i