Re: [PATCH 14/28] kvm tools: Fix term_getc(), term_getc_iov() endian bugs

2011-12-06 Thread Matt Evans
Hi Asias, On 06/12/11 23:00, Asias He wrote: > On 12/06/2011 06:24 PM, Pekka Enberg wrote: >> On Tue, Dec 6, 2011 at 5:40 AM, Matt Evans wrote: >>> term_getc()'s int c has one byte written into it (at its lowest address) by >>> read_in_full(). This is expected to be the least significant byte, b

Re: [PATCH 14/28] kvm tools: Fix term_getc(), term_getc_iov() endian bugs

2011-12-06 Thread Asias He
On 12/06/2011 06:24 PM, Pekka Enberg wrote: > On Tue, Dec 6, 2011 at 5:40 AM, Matt Evans wrote: >> term_getc()'s int c has one byte written into it (at its lowest address) by >> read_in_full(). This is expected to be the least significant byte, but that >> isn't the case on BE! Use correct type,

Re: [PATCH 14/28] kvm tools: Fix term_getc(), term_getc_iov() endian bugs

2011-12-06 Thread Pekka Enberg
On Tue, Dec 6, 2011 at 5:40 AM, Matt Evans wrote: > term_getc()'s int c has one byte written into it (at its lowest address) by > read_in_full().  This is expected to be the least significant byte, but that > isn't the case on BE!  Use correct type, unsigned char.  A similar issue > exists > in t

[PATCH 14/28] kvm tools: Fix term_getc(), term_getc_iov() endian bugs

2011-12-05 Thread Matt Evans
term_getc()'s int c has one byte written into it (at its lowest address) by read_in_full(). This is expected to be the least significant byte, but that isn't the case on BE! Use correct type, unsigned char. A similar issue exists in term_getc_iov(), which needs to write a char to the iov rather