nixos/wrappers: require argc to be at least one
setuid applications were exploited in the past with an emptyargv, such as pkexec using CVE-2021-4034.
Konrad Borowski 3 years ago 2a6a3d2c 1009d6e7
··· 170 170 } 171 171 172 172 int main(int argc, char **argv) { 173 173 + ASSERT(argc >= 1); 173 174 char *self_path = NULL; 174 175 int self_path_size = readlink_malloc("/proc/self/exe", &self_path); 175 176 if (self_path_size < 0) {