All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrange" <berrange@redhat.com>
To: qemu-devel@nongnu.org
Cc: Peter Maydell <peter.maydell@linaro.org>,
	"Daniel P. Berrange" <berrange@redhat.com>
Subject: [Qemu-devel] [PULL v1 2/2] io: fix FD socket handling in DNS lookup
Date: Tue,  4 Apr 2017 16:20:11 +0100	[thread overview]
Message-ID: <20170404152011.16119-3-berrange@redhat.com> (raw)
In-Reply-To: <20170404152011.16119-1-berrange@redhat.com>

The qio_dns_resolver_lookup_sync() method is required to be a no-op
for socket kinds that don't require name resolution. Thus the KIND_FD
handling should not return an error.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
---
 io/dns-resolver.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/io/dns-resolver.c b/io/dns-resolver.c
index a407075..759d1b4 100644
--- a/io/dns-resolver.c
+++ b/io/dns-resolver.c
@@ -158,16 +158,13 @@ int qio_dns_resolver_lookup_sync(QIODNSResolver *resolver,
 
     case SOCKET_ADDRESS_KIND_UNIX:
     case SOCKET_ADDRESS_KIND_VSOCK:
+    case SOCKET_ADDRESS_KIND_FD:
         return qio_dns_resolver_lookup_sync_nop(resolver,
                                                 addr,
                                                 naddrs,
                                                 addrs,
                                                 errp);
 
-    case SOCKET_ADDRESS_KIND_FD:
-        error_setg(errp, "Unsupported socket address type 'fd'");
-        return -1;
-
     default:
         abort();
     }
-- 
2.9.3

  parent reply	other threads:[~2017-04-04 15:20 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-04 15:20 [Qemu-devel] [PULL v1 0/2] Merge qio 2017/04/04 v1 Daniel P. Berrange
2017-04-04 15:20 ` [Qemu-devel] [PULL v1 1/2] io: fix incoming client socket initialization Daniel P. Berrange
2017-04-04 15:20 ` Daniel P. Berrange [this message]
2017-04-04 16:46 ` [Qemu-devel] [PULL v1 0/2] Merge qio 2017/04/04 v1 Peter Maydell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170404152011.16119-3-berrange@redhat.com \
    --to=berrange@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.