19 #include <grass/gis.h>
39 infp = fopen(infile,
"r");
41 G_warning(
"Cannot open %s for reading: %s", infile, strerror(errno));
45 outfp = fopen(outfile,
"w");
47 G_warning(
"Cannot open %s for writing: %s", outfile, strerror(errno));
51 while ((inchar = getc(infp)) != EOF) {
54 outchar = putc(inchar, outfp);
55 if (outchar != inchar) {
56 G_warning(
"Error writing to %s", outfile);