Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
- int main(int argc, char **argv) {
- FILE *file;
- file = fopen(argv[1], "r");
- char buf[600];
- char *pos;
- pid_t parent = fork();
- if(parent == 0) {
- while (fgets(buf, sizeof(buf), file)) {
- if ((pos=strchr(buf, 'n')))
- *pos = '