| | /* uusplt.c - Split concatenated uuencoded files into separate uue files */ |
---|
| | /* $Id: uusplt.c,v 1.1 1995/02/01 23:57:08 tundra Exp $ */ |
---|
| | /* $Id: uusplt.c,v 1.2 1995/02/02 16:59:43 tundra Exp $ */ |
---|
| | |
---|
| | #include <stdio.h> |
---|
| | #include <strings.h> |
---|
| | void begun(); |
---|
| | static int cnt; |
---|
| | |
---|
| | main() |
---|
| | |
---|
| | { |
---|
| | |
---|
| | char buf[1001]; |
---|
| | |
---|
| | cnt = 0; |
---|
| | while(fgets(buf, 1000, stdin) != NULL) |
---|
| | { |
---|
| | if (strncmp("begin",buf, 5) == 0) |
---|
| | begun(buf); |
---|
| | { |
---|
| | begun(buf); |
---|
| | cnt++; |
---|
| | } |
---|
| | } |
---|
| | printf("%d UUencoded Files Found.\n", cnt); |
---|
| | } |
---|
| | |
---|
| | void begun(buf) |
---|
| | char *buf; |
---|
| |
---|
| | printf("Hosed File Open For %s!", nm); |
---|
| | exit(); |
---|
| | } |
---|
| | |
---|
| | printf("%s\n", nm); |
---|
| | while(strncmp("end", buf, 3) != 0) |
---|
| | { |
---|
| | fputs(buf, fd); |
---|
| | fgets(buf, 1000, stdin); |
---|
| |
---|
| | |
|