[sheepdog] [PATCH] collie: use xread and xwrite instead of read and write

Liu Yuan namei.unix at gmail.com
Fri Aug 2 11:20:03 CEST 2013


On Fri, Aug 02, 2013 at 06:05:31PM +0900, MORITA Kazutaka wrote:
> From: MORITA Kazutaka <morita.kazutaka at lab.ntt.co.jp>
> 
> The following code in vdi_read() is wrong
> 
>    write(STDOUT_FILENO, buf + (len - remain), len)
> 
> The number of bytes to be written should be 'remain'.
> 
> Rather than fixing it, this patch replaces them with xread() and
> xwrite(), which don't return a short length on success.

Applied thanks

Yuan



More information about the sheepdog mailing list