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

Re: sparc64 breakage



On Tue, 23 Mar 2004 07:50:21 +0100
Damien Couderc <coudercd_(_at_)_nerim_(_dot_)_net> wrote:

> > Yes, it should be, but it is not. At least not on sparc64. When
> > reading the cache, len is defined as 'size_t', but when writing - as
> > 'gint'. Should probably be defined as 'gint' in both places.
> 
> Right, could you test it ? I don't have imap accounts to do it.

Yes, it works fine. This is the patch I use:


$OpenBSD$
--- src/procmsg.c.orig	2004-01-27 21:48:37.000000000 -0600
+++ src/procmsg.c	2004-03-18 21:04:12.000000000 -0600
@@ -128,7 +128,7 @@ static gint procmsg_read_cache_data_str(
 {
 	gchar buf[BUFFSIZE];
 	gint ret = 0;
-	size_t len;
+	gint len;
 
 	if (fread(&len, sizeof(len), 1, fp) == 1) {
 		if (len < 0)
@@ -137,7 +137,7 @@ static gint procmsg_read_cache_data_str(
 			gchar *tmp = NULL;
 
 			while (len > 0) {
-				size_t size = MIN(len, BUFFSIZE - 1);
+				gint size = MIN(len, BUFFSIZE - 1);
 
 				if (fread(buf, size, 1, fp) != 1) {
 					ret = -1;



Visit your host, monkey.org