WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] gcc-4.0 - get_header

To: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] gcc-4.0 - get_header
From: Flavio Leitner <fbl@xxxxxxxxxxxxxxxx>
Date: Fri, 24 Jun 2005 15:01:35 -0300
Delivery-date: Fri, 24 Jun 2005 18:00:53 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.9i
Hello!

get_header() use image as unsigned char and must be that way
because of operations with bit shifting but gcc4 dislike it.

----

signedness fix for gcc-4.0
(get_header)

Signed-off-by: Flavio B. Leitner <fbl@xxxxxxxxxxxxxxxx>


===== tools/libxc/xc_load_aout9.c 1.1 vs edited =====
--- 1.1/tools/libxc/xc_load_aout9.c     2005-06-24 06:51:37 -04:00
+++ edited/tools/libxc/xc_load_aout9.c  2005-06-24 10:33:30 -04:00
@@ -30,7 +30,7 @@ probe_aout9(
 {
     struct Exec ehdr;
 
-    if (!get_header(image, image_size, &ehdr)) {
+    if (!get_header((unsigned char *) image, image_size, &ehdr)) {
         ERROR("Kernel image does not have a a.out9 header.");
         return -EINVAL;
     }
@@ -49,7 +49,7 @@ parseaout9image(
     struct Exec ehdr;
     unsigned long start, txtsz, end;
 
-    if (!get_header(image, image_size, &ehdr)) {
+    if (!get_header((unsigned char *) image, image_size, &ehdr)) {
         ERROR("Kernel image does not have a a.out9 header.");
         return -EINVAL;
     }
@@ -85,7 +85,7 @@ loadaout9image(
     struct Exec ehdr;
     unsigned long txtsz;
 
-    if (!get_header(image, image_size, &ehdr)) {
+    if (!get_header((unsigned char *) image, image_size, &ehdr)) {
         ERROR("Kernel image does not have a a.out9 header.");
         return -EINVAL;
     }

-- 
Flávio Bruno Leitner <fbl@xxxxxxxxxxxxxxxx>
[0EA2 7F40 4CF4 1E63 4AF6  33C0 3E10 E205 F251 EDDA]

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] gcc-4.0 - get_header, Flavio Leitner <=