From: Frédéric Marchal Date: Sun, 15 Jul 2012 12:38:08 +0000 (+0200) Subject: Use the same message to report an error while deleting a file X-Git-Tag: v2.3.3~42 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7c4264ec147829d8e9f18bc1569e46f5957396f2;p=thirdparty%2Fsarg.git Use the same message to report an error while deleting a file No need to burden the translators with multiple messages identical but for a few characters. --- diff --git a/index.c b/index.c index e676887..d6af010 100644 --- a/index.c +++ b/index.c @@ -44,7 +44,7 @@ void make_index(void) sprintf(wdir,"%sindex.html",outdir); if(access(wdir, R_OK) == 0) { if (unlink(wdir)) { - debuga(_("Cannot delete %s - %s\n"),wdir,strerror(errno)); + debuga(_("Cannot delete \"%s\": %s\n"),wdir,strerror(errno)); exit(EXIT_FAILURE); } } diff --git a/indexonly.c b/indexonly.c index a6f430a..c1c5684 100644 --- a/indexonly.c +++ b/indexonly.c @@ -47,7 +47,7 @@ void index_only(const char *dirname,int debug) continue; } if (unlink(remove) == -1) { - debuga(_("Failed to remove the file %s: %s\n"),remove,strerror(errno)); + debuga(_("Cannot delete \"%s\": %s\n"),remove,strerror(errno)); } } diff --git a/lastlog.c b/lastlog.c index d7352d8..1db4190 100644 --- a/lastlog.c +++ b/lastlog.c @@ -84,7 +84,7 @@ void mklastlog(const char *outdir) } if (unlink(temp)) { - debuga(_("Cannot delete %s - %s\n"),temp,strerror(errno)); + debuga(_("Cannot delete \"%s\": %s\n"),temp,strerror(errno)); exit(EXIT_FAILURE); } @@ -92,7 +92,7 @@ void mklastlog(const char *outdir) snprintf(temp,sizeof(temp),"%slastlog",outdir); if(access(temp, R_OK) == 0) { if (unlink(temp)) { - debuga(_("Cannot delete %s - %s\n"),temp,strerror(errno)); + debuga(_("Cannot delete \"%s\": %s\n"),temp,strerror(errno)); exit(EXIT_FAILURE); } } @@ -128,7 +128,7 @@ void mklastlog(const char *outdir) fclose(fp_in); snprintf(temp,sizeof(temp),"%slastlog",outdir); if (unlink(temp) == -1) { - debuga(_("Failed to delete the file %s\n"),temp); + debuga(_("Cannot delete \"%s\": %s\n"),temp,strerror(errno)); } return; diff --git a/util.c b/util.c index 419c3e6..0cdee15 100644 --- a/util.c +++ b/util.c @@ -1832,7 +1832,7 @@ void unlinkdir(const char *dir,int contentonly) } if (S_ISREG(st.st_mode)) { if (unlink(dname)) { - debuga(_("cannot delete %s - %s\n"),dname,strerror(errno)); + debuga(_("Cannot delete \"%s\": %s\n"),dname,strerror(errno)); exit(EXIT_FAILURE); } } else if (S_ISDIR(st.st_mode)) { @@ -1845,7 +1845,7 @@ void unlinkdir(const char *dir,int contentonly) if (!contentonly) { if (rmdir(dir)) { - debuga(_("cannot delete %s - %s\n"),dir,strerror(errno)); + debuga(_("Cannot delete \"%s\": %s\n"),dir,strerror(errno)); exit(EXIT_FAILURE); } }