Re: [Qemu-devel] [PATCH v5 3/4] net/net: Convert parse_host_port() to Error

2017-06-28 Thread Mao Zhongyi
On 06/28/2017 06:56 PM, Markus Armbruster wrote: Paolo Bonzini writes: On 28/06/2017 07:51, Markus Armbruster wrote: The gethostbyname() return a null pointer if an error occurs, and the h_errno variable holds an error number. herror() and hstrerror() can prints the

Re: [Qemu-devel] [PATCH v5 3/4] net/net: Convert parse_host_port() to Error

2017-06-28 Thread Markus Armbruster
Paolo Bonzini writes: > On 28/06/2017 07:51, Markus Armbruster wrote: >>> The gethostbyname() return a null pointer if an error occurs, and the >>> h_errno >>> variable holds an error number. herror() and hstrerror() can prints the >>> error >>> message associated with the

Re: [Qemu-devel] [PATCH v5 3/4] net/net: Convert parse_host_port() to Error

2017-06-28 Thread Paolo Bonzini
On 28/06/2017 07:51, Markus Armbruster wrote: >> The gethostbyname() return a null pointer if an error occurs, and the h_errno >> variable holds an error number. herror() and hstrerror() can prints the error >> message associated with the current value of h_errno, but hstrerror() returns >> the

Re: [Qemu-devel] [PATCH v5 3/4] net/net: Convert parse_host_port() to Error

2017-06-27 Thread Markus Armbruster
Mao Zhongyi writes: > Hi, Markus > > On 06/27/2017 04:04 PM, Markus Armbruster wrote: >> Mao Zhongyi writes: >> >>> Cc: berra...@redhat.com >>> Cc: kra...@redhat.com >>> Cc: pbonz...@redhat.com >>> Cc: jasow...@redhat.com >>> Cc:

Re: [Qemu-devel] [PATCH v5 3/4] net/net: Convert parse_host_port() to Error

2017-06-27 Thread Mao Zhongyi
Hi, Markus On 06/27/2017 04:04 PM, Markus Armbruster wrote: Mao Zhongyi writes: Cc: berra...@redhat.com Cc: kra...@redhat.com Cc: pbonz...@redhat.com Cc: jasow...@redhat.com Cc: arm...@redhat.com Signed-off-by: Mao Zhongyi ---

Re: [Qemu-devel] [PATCH v5 3/4] net/net: Convert parse_host_port() to Error

2017-06-27 Thread Markus Armbruster
Mao Zhongyi writes: > Cc: berra...@redhat.com > Cc: kra...@redhat.com > Cc: pbonz...@redhat.com > Cc: jasow...@redhat.com > Cc: arm...@redhat.com > Signed-off-by: Mao Zhongyi > --- > include/qemu/sockets.h | 3 ++- > net/net.c

[Qemu-devel] [PATCH v5 3/4] net/net: Convert parse_host_port() to Error

2017-06-26 Thread Mao Zhongyi
Cc: berra...@redhat.com Cc: kra...@redhat.com Cc: pbonz...@redhat.com Cc: jasow...@redhat.com Cc: arm...@redhat.com Signed-off-by: Mao Zhongyi --- include/qemu/sockets.h | 3 ++- net/net.c | 22 +- net/socket.c | 19