Seconding thanks for this link!
Type: Posts; User: s1mon
Seconding thanks for this link!
Why? The signal handler should do as little as possible - for example, changing a global variable. Then it is your main code's job of checking for that variable. The op can just break out of the loop...
I assume you want to compile your app for debugging with gdb ?
Very good resource.
If you are interested in Linux, then I advise Understanding the Linux Kernel. Alongside xhi's recomendation of Linux Device Drivers, my knowledge of the Linux kernel has been...
Try changing this to:
if ((fd1 = open(argv[1], O_RDONLY)) == -1) {
perror("problem with open in lchars: 1");
exit(-1);
}
if ((fd2 =...