[systemd-commits] src/resolve

Lennart Poettering lennart at kemper.freedesktop.org
Wed Aug 20 05:48:25 PDT 2014


 src/resolve/resolved-dns-domain.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit be754d5443e5fe44ead733ad509b127409cdb0f0
Author: Lennart Poettering <lennart at poettering.net>
Date:   Wed Aug 20 14:47:35 2014 +0200

    resolved: fix which return codes we check
    
    Discovered by Lukas Nykryn

diff --git a/src/resolve/resolved-dns-domain.c b/src/resolve/resolved-dns-domain.c
index 6152047..8ed1ecf 100644
--- a/src/resolve/resolved-dns-domain.c
+++ b/src/resolve/resolved-dns-domain.c
@@ -434,8 +434,8 @@ int dns_name_endswith(const char *name, const char *suffix) {
                         saved_n = n;
 
                 q = dns_label_unescape(&s, ls, sizeof(ls));
-                if (r < 0)
-                        return r;
+                if (q < 0)
+                        return q;
                 w = dns_label_undo_idna(ls, q, ls, sizeof(ls));
                 if (w < 0)
                         return w;



More information about the systemd-commits mailing list