From: Bruno Haible Date: Fri, 6 Oct 2006 13:27:49 +0000 (+0000) Subject: Use the new _temp functions from the create-temp module. X-Git-Tag: 0.16.x-branchpoint~103 X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=5e58c7b791bd530b7dc47b197774aa23d797c462;p=thirdparty%2Fgettext.git Use the new _temp functions from the create-temp module. --- diff --git a/gettext-tools/src/ChangeLog b/gettext-tools/src/ChangeLog index 5d81bcc33..14b5a6dd5 100644 --- a/gettext-tools/src/ChangeLog +++ b/gettext-tools/src/ChangeLog @@ -1,3 +1,9 @@ +2006-10-06 Bruno Haible + + * write-java.c (msgdomain_write_java): Use fopen_temp, fwriteerror_temp + instead of fopen, fwriteerror. + * write-csharp.c (msgdomain_write_csharp): Likewise. + 2006-10-06 Bruno Haible * Makefile.am (LTV_CURRENT, LTV_REVISION, LTV_AGE): Bump to 3:0:3. diff --git a/gettext-tools/src/write-csharp.c b/gettext-tools/src/write-csharp.c index 40da40581..75f9fee83 100644 --- a/gettext-tools/src/write-csharp.c +++ b/gettext-tools/src/write-csharp.c @@ -715,7 +715,7 @@ but the C# .dll format doesn't support contexts\n"))); /* Create the C# file. */ register_temp_file (tmpdir, csharp_file_name); - csharp_file = fopen (csharp_file_name, "w"); + csharp_file = fopen_temp (csharp_file_name, "w"); if (csharp_file == NULL) { error (0, errno, _("failed to create \"%s\""), csharp_file_name); @@ -725,7 +725,7 @@ but the C# .dll format doesn't support contexts\n"))); write_csharp_code (csharp_file, culture_name, class_name, mlp); - if (fwriteerror (csharp_file)) + if (fwriteerror_temp (csharp_file)) { error (0, errno, _("error while writing \"%s\" file"), csharp_file_name); goto quit3; diff --git a/gettext-tools/src/write-java.c b/gettext-tools/src/write-java.c index af0b3e437..6b216460e 100644 --- a/gettext-tools/src/write-java.c +++ b/gettext-tools/src/write-java.c @@ -1002,7 +1002,7 @@ but the Java ResourceBundle format doesn't support contexts\n"))); /* Create the Java file. */ register_temp_file (tmpdir, java_file_name); - java_file = fopen (java_file_name, "w"); + java_file = fopen_temp (java_file_name, "w"); if (java_file == NULL) { error (0, errno, _("failed to create \"%s\""), java_file_name); @@ -1012,7 +1012,7 @@ but the Java ResourceBundle format doesn't support contexts\n"))); write_java_code (java_file, class_name, mlp, assume_java2); - if (fwriteerror (java_file)) + if (fwriteerror_temp (java_file)) { error (0, errno, _("error while writing \"%s\" file"), java_file_name); goto quit3;