OSDN Git Service

- standardize fopen error message a bit
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Thu, 9 Oct 2008 12:21:41 +0000 (12:21 -0000)
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Thu, 9 Oct 2008 12:21:41 +0000 (12:21 -0000)
extra/locale/gen_collate.c
extra/locale/gen_ldc.c
extra/locale/gen_locale.c
extra/locale/gen_mmap.c
extra/locale/gen_wc8bit.c
extra/locale/gen_wctype.c
extra/locale/lmmtolso.c

index 77dc5ff..58464a2 100644 (file)
@@ -1253,7 +1253,7 @@ static int old_main(int argc, char **argv)
                FILE *fp = fopen("locale_collate.h", "w");
 
                if (!fp) {
-                       error_msg("couldn't open output file!");
+                       error_msg("cannot open output file!");
                }
                dump_collate(fp);
                if (ferror(fp) || fclose(fp)) {
index 08cd855..2cedbdd 100644 (file)
@@ -162,7 +162,7 @@ int main(int argc, char **argv)
        if (argc == 2)
                output_file = argv[1];
        if (!(lso = fopen(output_file, "w"))) {
-               printf("can't open output file '%s'!\n", output_file);
+               printf("cannot open output file '%s'!\n", output_file);
                return EXIT_FAILURE;
        }
 
index 200e630..936883e 100644 (file)
@@ -584,7 +584,7 @@ int main(int argc, char **argv)
        if (argc == 3)
                output_file = *++argv;
        if (output_file == NULL || !(ofp = fopen(output_file, "w"))) {
-               printf("error: can not open outputfile '%s' for writing!\n",
+               printf("cannot open output file '%s'!\n",
                        output_file);
                return EXIT_FAILURE;
        }
index f9bce02..1cf0bb9 100644 (file)
@@ -127,7 +127,7 @@ int main(void)
        unsigned char *p;
 
        if (!(fp = fopen("locale.mmap", "w"))) {
-               printf("error - can't open locale.mmap for writing!");
+               printf("cannot open locale.mmap for writing!");
                return EXIT_FAILURE;
        }
 
index c6db412..20f8f64 100644 (file)
@@ -103,7 +103,7 @@ int main(int argc, char **argv)
        }
 
        if (!(out = fopen("c8tables.h","w"))) {
-               printf("error: couldn't open file \"c8tables.h\"\n");
+               printf("cannot open output file 'c8tables.h'!\n");
                return EXIT_FAILURE;
        }
 
@@ -173,7 +173,7 @@ int main(int argc, char **argv)
        codeset_index[0] = 0;
        while (--argc) {
                if (!(fp = fopen(*++argv,"r"))) {
-                       printf("error: couldn't open file \"%s\"\n", *argv);
+                       printf("cannot open file \"%s\"\n", *argv);
                        return EXIT_FAILURE;
                }
                printf("processing %s... ", *argv);
index 68fb26e..6bfc40b 100644 (file)
@@ -740,7 +740,7 @@ int main(int argc, char **argv)
                FILE *fp;
 
                if (!(fp = fopen("wctables.h", "w"))) {
-                       printf("couldn't open wctables.h!\n");
+                       printf("cannot open output file 'wctables.h'!\n");
                        return EXIT_FAILURE;
                }
 
index a1876a7..2437a8f 100644 (file)
@@ -14,18 +14,18 @@ int main(void)
        size_t i;
 
        if (!(lmm = fopen("locale.mmap", "r"))) {
-               printf("can't open locale.mmap!\n");
+               printf("cannot open locale.mmap!\n");
                return EXIT_FAILURE;
        }
 
        if (fstat(fileno(lmm), &fd_stat)) {
-               printf("can't stat locale.mmap!\n");
+               printf("cannot stat locale.mmap!\n");
                fclose(lmm);
                return EXIT_FAILURE;
        }
 
        if (!(lso = fopen("locale_data.c", "w"))) {
-               printf("can't open locale_data.c!\n");
+               printf("cannot open locale_data.c!\n");
                fclose(lmm);
                return EXIT_FAILURE;
        }