Re: Compiling errors with latest version from GIT, Printing of HTML Messages



Hi Albrecht:

On 04/14/2017 01:16:41 PM Fri, Albrecht Dreß wrote:
Hi John Jack Doe:

Am 14.04.17 18:24 schrieb(en) JohnJackDoe tele2 de:
1. I currently run the balsa version 2.5.3a-32-g98a0d88 from GIT. The latest version from GIT is not 
compiling. Please see the attached display output. Any ideas?

You are compiling on a box where glib's gsize is typedef'ed as "unsigned int", not "unsigned long" as for 
Ubuntu 16.04 LTS/64 bit, and therefore the format specifier is wrong.  Please try the attached patch, which should fix the issue. 
 Note that I /might/ have made the same assumption in other places, too.  You can try 'make -k' after adding the patch to collect 
all of them.  Please tell me if there are more cases like these.  Thanks for pointing me to that!

Side note: I think the "usual" approach by adding the glib-specific format strings (i.e. '_("Message %" G_GSIZE_FORMAT " of 
%" G_GSIZE_FORMAT " (%s of %s)")') will break gettext, see 
<https://www.gnu.org/software/gettext/manual/html_node/Preparing-Strings.html>, so the cast seems to be better to me.  Or does the glib '_()' macro 
cover this case?

Elsewhere in Balsa code, gsize is cast to unsigned long to print using %lu, so that looks like an appropriate 
fix here.

Best,

Peter


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