c - How can i perform my exe file from boot.local -
i've written code boosting priority of process on opensuse 12.2 system. #include <stdio.h> #include <sched.h> #include <unistd.h> int printusage(void) { printf("\nusage:\nboostprio [pid] [priority: (0-99)] [policy: ff:rr:oth]\n"); exit (1); } int main (int argc , char *argv[]) { int pid = -1 ; int pri; struct sched_param param; if(argc != 4 ){ printf("\nargument miss match !!"); printusage(); return -1; } if((strcmp(argv[1],"-h" ) == 0) || (strcmp(argv[1],"--help") == 0)) printusage(); pid = atoi(argv[1]); if(pid <= 0){ printf("\npid not correct!!\n"); return -1; } pri = atoi(argv[2]); if((pri > 99) || (pri < 0)){ printf("\npriority value not valid !!\n"); return -1; } param.sched_priority = pri; if(strcmp(argv[3],"ff") == 0) sche...