ia64/xen-unstable

changeset 3641:b66cde79fd78

bitkeeper revision 1.1159.241.3 (4202bcfcMuCoA62roOJu-r3AKctkBQ)

strncpy will stop after a zero byte. Use memcpy instead.

Signed-off-by: Chengyuan Li <chengyuan.li@intel.com>
Signed-off-by: ian.pratt@cl.cam.ac.uk
author iap10@labyrinth.cl.cam.ac.uk
date Fri Feb 04 00:08:28 2005 +0000 (2005-02-04)
parents 44232b00c34a
children 26a00896163a
files xen/arch/x86/vmx_platform.c
line diff
     1.1 --- a/xen/arch/x86/vmx_platform.c	Fri Feb 04 00:05:42 2005 +0000
     1.2 +++ b/xen/arch/x86/vmx_platform.c	Fri Feb 04 00:08:28 2005 +0000
     1.3 @@ -372,7 +372,7 @@ static int inst_copy_from_guest(char *bu
     1.4          ma = (mfn << PAGE_SHIFT) | (guest_eip & (PAGE_SIZE - 1));
     1.5          inst_start = (unsigned char *)map_domain_mem(ma);
     1.6                  
     1.7 -        strncpy(buf, inst_start, inst_len);
     1.8 +        memcpy(buf, inst_start, inst_len);
     1.9          unmap_domain_mem(inst_start);
    1.10      } else {
    1.11          // Todo: In two page frames