Package: gai
Version: 0.5.8-1
Severity: normal
Tags: patch
When building 'gai' on amd64/unstable with gcc-4.0,
I get the following error:
gai-pref2.c:874: error: invalid lvalue in assignment
gai-pref2.c:899: warning: cast from pointer to integer of different size
make[2]: *** [gai-pref2.o] Error 1
make[2]: Leaving directory `/gai-0.5.8/gai'
With the attached patch 'gai' can be compiled
on amd64 using gcc-4.0.
Regards
Andreas Jochens
diff -urN ../tmp-orig/gai-0.5.8/gai/gai-pref.c ./gai/gai-pref.c
--- ../tmp-orig/gai-0.5.8/gai/gai-pref.c 2004-03-18 08:56:35.000000000
+0100
+++ ./gai/gai-pref.c 2005-04-08 08:55:52.528705398 +0200
@@ -967,8 +967,8 @@
if((unsigned char*)(((int *)iw[i].result)[0]) != NULL &&
(unsigned char*)(((int *)iw[i].default_val)[0]) != NULL)
- (unsigned char*)(((int *)iw[i].result)[0]) =
- (unsigned char*)(((int *)iw[i].default_val)[0]) =
g_strdup(buff);
+ (((int *)iw[i].result)[0]) =
+ (((int *)iw[i].default_val)[0]) = g_strdup(buff);
//printf("%s\n",buff);
@@ -988,7 +988,7 @@
if(j == g_list_length((GList *)((int *)iw[i].result)[0])){
- (GList *)((int *)iw[i].result)[0] = g_list_append((GList
*)((int *)iw[i].result)[0],
+ ((int *)iw[i].result)[0] = g_list_append((GList *)((int
*)iw[i].result)[0],
g_strdup(buff));
// printf("%s is a new entry\n",buff);
}
diff -urN ../tmp-orig/gai-0.5.8/gai/gai-pref2.c ./gai/gai-pref2.c
--- ../tmp-orig/gai-0.5.8/gai/gai-pref2.c 2004-09-12 10:17:58.000000000
+0200
+++ ./gai/gai-pref2.c 2005-04-08 08:55:03.474457046 +0200
@@ -870,7 +870,7 @@
if(j == g_list_length((GList *)((int *)iw[i].result)[0])){
- (GList *)((int *)iw[i].result)[0] = g_list_append((GList
*)((int *)iw[i].result)[0],
+ ((int *)iw[i].result)[0] = g_list_append((GList *)((int
*)iw[i].result)[0],
g_strdup(buff));
}
((int *)iw[i].result2)[0] = j;
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]