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

[Xen-changelog] [xen-unstable] [XEN] Fix build breakage with gcc 4.1.2.



# HG changeset patch
# User Ian Campbell <ian.campbell@xxxxxxxxxxxxx>
# Date 1170240038 0
# Node ID c834e3984baa231d32689e74ddd8ce8850b682ce
# Parent  daed6ac9d1f78711b19fd35b12319b509c7b0a9f
[XEN] Fix build breakage with gcc 4.1.2.

domain_build.c: In function 'construct_dom' :
domain_build.c:874: warning: pointer targets in passing argument 1 of 'strlcpy' 
differ in signedness

Unfortunately adding a simple cast to (char *) doesn't work since that
confuses safe_strcpy so revert to using strlcpy directly.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxxxxx>
---
 xen/arch/x86/domain_build.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -r daed6ac9d1f7 -r c834e3984baa xen/arch/x86/domain_build.c
--- a/xen/arch/x86/domain_build.c       Wed Jan 31 10:25:12 2007 +0000
+++ b/xen/arch/x86/domain_build.c       Wed Jan 31 10:40:38 2007 +0000
@@ -871,7 +871,7 @@ int construct_dom0(struct domain *d,
 
     memset(si->cmd_line, 0, sizeof(si->cmd_line));
     if ( cmdline != NULL )
-        safe_strcpy(si->cmd_line, cmdline);
+        strlcpy((char *)si->cmd_line, cmdline, sizeof(si->cmd_line));
 
     if ( fill_console_start_info((void *)(si + 1)) )
     {

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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.