127 is the "command not found" shell exeit code, 126 is "the command
file is found but is not executable" which i think i'd interpret not
just for execute permissions but that something is preventing it from
executing in general.
close(devnull);
}
- if (!(loop = efl_provider_find(obj, EFL_LOOP_CLASS))) exit(-120);
+ if (!(loop = efl_provider_find(obj, EFL_LOOP_CLASS))) exit(1);
- if (!(tdl = efl_data_scope_get(loop, EFL_TASK_CLASS))) exit(-121);
+ if (!(tdl = efl_data_scope_get(loop, EFL_TASK_CLASS))) exit(1);
// clear systemd notify socket... only relevant for systemd world,
// otherwise shouldn't be trouble
// actually execute!
_exec(cmd, pd->flags);
// we couldn't exec... uh oh. HAAAAAAAALP!
- exit(-122);
+ if ((errno == EACCES) || (errno == EINVAL) || (errno == ELOOP) ||
+ (errno == ENOEXEC) || (errno == ENOMEM))
+ exit(126);
+ exit(127);
return NULL;
#endif
}