[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 4/9] qemu-sockets: add error propagation to U
From: |
Luiz Capitulino |
Subject: |
Re: [Qemu-devel] [PATCH v2 4/9] qemu-sockets: add error propagation to Unix socket functions |
Date: |
Mon, 1 Oct 2012 20:05:07 -0300 |
On Mon, 01 Oct 2012 21:07:52 +0200
Paolo Bonzini <address@hidden> wrote:
> Il 01/10/2012 19:17, Luiz Capitulino ha scritto:
> >> > if (bind(sock, (struct sockaddr*) &un, sizeof(un)) < 0) {
> >> > - fprintf(stderr, "bind(unix:%s): %s\n", un.sun_path,
> >> > strerror(errno));
> >> > + error_set(errp, QERR_SOCKET_BIND_FAILED);
> > This drops error information, making the error message worse. I believe
> > you have a reason to not use error_setg()?
>
> I was waiting for the end of the discussion on errno to add
> error_setg_errno.
The decision was to not add errno now, right?
> > Also, I see that in some hunks you do something like:
> >
> > - fd = unix_listen_opts(opts);
> > + fd = unix_listen_opts(opts, NULL);
> >
> > This will break printing the error message to the user. It's fine by me if
> > you do this only temporarily (ie. this is fixed by the next or a later
> > patch),
> > but want to double check that you're aware of it.
>
> I want to avoid super-large patch series, so I would prefer to fix it
> later in the 1.3 development.
We at least need to have the patches flying, I don't think it's ok to
break error reporting like that.
- Re: [Qemu-devel] [PATCH v2 2/9] qapi: add socket address types, (continued)
Re: [Qemu-devel] [PATCH v2 2/9] qapi: add socket address types, Luiz Capitulino, 2012/10/02
[Qemu-devel] [PATCH v2 3/9] qemu-sockets: add error propagation to inet_parse, Paolo Bonzini, 2012/10/01
[Qemu-devel] [PATCH v2 4/9] qemu-sockets: add error propagation to Unix socket functions, Paolo Bonzini, 2012/10/01
[Qemu-devel] [PATCH v2 7/9] block: add close notifiers, Paolo Bonzini, 2012/10/01
[Qemu-devel] [PATCH v2 5/9] qemu-sockets: return IPSocketAddress from inet_parse, Paolo Bonzini, 2012/10/01
[Qemu-devel] [PATCH v2 6/9] qemu-sockets: add socket_listen, socket_connect, socket_parse, Paolo Bonzini, 2012/10/01
[Qemu-devel] [PATCH v2 8/9] qmp: add NBD server commands, Paolo Bonzini, 2012/10/01