bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

meaningless msgmerge error message in case of charset problems (fwd)


From: Santiago Vila
Subject: meaningless msgmerge error message in case of charset problems (fwd)
Date: Fri, 8 Jul 2005 13:38:13 +0200 (CEST)

Hello.

I received this from the Debian bug system:

---------- Forwarded message ----------
From: Hans Ulrich Niedermann <address@hidden>
To: Debian Bug Tracking System <address@hidden>
Cc: address@hidden
Date: Thu, 21 Apr 2005 17:07:36 +0200
Subject: meaningless msgmerge error message in case of charset problems

Package: gettext
Version: 0.14.4-1
Severity: minor
File: /usr/bin/msgmerge


When running msgmerge on a ja.po file with

,-----
|# Copyright \251 2000-2002 Free Software Foundation, Inc.
`-----

(note the iso-8859-1 (C) copyright character octal 251 in the comment)
and with

,-----
|"Content-Type: text/plain; charset=euc-jp\n"
`-----

in the specification, I got this meaningless error message:

,-----
|msgmerge: conversion failure
`-----

It only has a meaning if you already know what the problem is. I suggest
augmenting the error message like this:

--- gettext-tools/src/msgl-iconv.c.orig 2003-12-19 12:17:28.000000000 +0100
+++ gettext-tools/src/msgl-iconv.c      2005-04-21 16:33:01.000000000 +0200
@@ -184,7 +184,7 @@
        && strlen (result) == resultlen - 1)
       return result;
 
-  error (EXIT_FAILURE, 0, _("conversion failure"));
+  error (EXIT_FAILURE, 0, _("iconv charset conversion failure"));
   /* NOTREACHED */
   return NULL;
 }

This makes it clear that there is some problem with the character
encoding, which makes it possible to find the problem within minutes
instead of within days.

Apart from that, it may possibly be desirable for msgmerge & Co. to
  - only consider the strings in msgid "" and msgstr "" to be encoded in
    the given charset
  - ignore 8-bin characters found in .po file comments
but I don't think this is important.

Error messages which actually point the user to the cause of the
problem are more interesting.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]