my-pkgs/acpilight/xbacklight.c

18 lines
269 B
C
Raw Normal View History

2022-07-08 08:24:58 +00:00
#include <unistd.h>
#include <stdlib.h>
int main (int argc, char** argv)
{
int i;
char** args;
args = malloc((argc+1)*sizeof(char*));
for(i = 0; i < argc; ++i) {
args[i] = argv[i];
}
args[argc] = NULL;
execv("/opt/xbacklight", args);
return 0;
}