|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
From be754d5443e5fe44ead733ad509b127409cdb0f0 Mon Sep 17 00:00:00 2001
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
From: Lennart Poettering <lennart@poettering.net>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Date: Wed, 20 Aug 2014 14:47:35 +0200
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Subject: [PATCH] resolved: fix which return codes we check
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Discovered by Lukas Nykryn
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
---
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
src/resolve/resolved-dns-domain.c | 4 ++--
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
diff --git a/src/resolve/resolved-dns-domain.c b/src/resolve/resolved-dns-domain.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
index 6152047ecb..8ed1ecf0a4 100644
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
--- a/src/resolve/resolved-dns-domain.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+++ b/src/resolve/resolved-dns-domain.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -434,8 +434,8 @@ int dns_name_endswith(const char *name, const char *suffix) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
saved_n = n;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
q = dns_label_unescape(&s, ls, sizeof(ls));
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- if (r < 0)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- return r;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ if (q < 0)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ return q;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
w = dns_label_undo_idna(ls, q, ls, sizeof(ls));
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (w < 0)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return w;
|