|
Fabiano Fidêncio |
32f2c81 |
From 94897e5c82967528dae2a79e42cd1eb3c3be68f3 Mon Sep 17 00:00:00 2001
|
|
Fabiano Fidêncio |
32f2c81 |
From: =?UTF-8?q?Fabiano=20Fid=C3=AAncio?= <fidencio@redhat.com>
|
|
Fabiano Fidêncio |
32f2c81 |
Date: Tue, 27 Mar 2018 15:02:09 +0200
|
|
Fabiano Fidêncio |
32f2c81 |
Subject: [PATCH 15/15] KCM: Only print the number of found items after we have
|
|
Fabiano Fidêncio |
32f2c81 |
it
|
|
Fabiano Fidêncio |
32f2c81 |
MIME-Version: 1.0
|
|
Fabiano Fidêncio |
32f2c81 |
Content-Type: text/plain; charset=UTF-8
|
|
Fabiano Fidêncio |
32f2c81 |
Content-Transfer-Encoding: 8bit
|
|
Fabiano Fidêncio |
32f2c81 |
|
|
Fabiano Fidêncio |
32f2c81 |
With the current code we've been always printing "Found 0 items" as
|
|
Fabiano Fidêncio |
32f2c81 |
state->sec_key_list_len is only set by sec_list_parse().
|
|
Fabiano Fidêncio |
32f2c81 |
|
|
Fabiano Fidêncio |
32f2c81 |
In order to solve this, let's just print it *after* we have
|
|
Fabiano Fidêncio |
32f2c81 |
state->sec_key_list_len set.
|
|
Fabiano Fidêncio |
32f2c81 |
|
|
Fabiano Fidêncio |
32f2c81 |
Signed-off-by: Fabiano FidĂȘncio <fidencio@redhat.com>
|
|
Fabiano Fidêncio |
32f2c81 |
|
|
Fabiano Fidêncio |
32f2c81 |
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com>
|
|
Fabiano Fidêncio |
32f2c81 |
---
|
|
Fabiano Fidêncio |
32f2c81 |
src/responder/kcm/kcmsrv_ccache_secrets.c | 2 +-
|
|
Fabiano Fidêncio |
32f2c81 |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
Fabiano Fidêncio |
32f2c81 |
|
|
Fabiano Fidêncio |
32f2c81 |
diff --git a/src/responder/kcm/kcmsrv_ccache_secrets.c b/src/responder/kcm/kcmsrv_ccache_secrets.c
|
|
Fabiano Fidêncio |
32f2c81 |
index 8a7a577d8..f2b46460e 100644
|
|
Fabiano Fidêncio |
32f2c81 |
--- a/src/responder/kcm/kcmsrv_ccache_secrets.c
|
|
Fabiano Fidêncio |
32f2c81 |
+++ b/src/responder/kcm/kcmsrv_ccache_secrets.c
|
|
Fabiano Fidêncio |
32f2c81 |
@@ -207,7 +207,6 @@ static void sec_list_done(struct tevent_req *subreq)
|
|
Fabiano Fidêncio |
32f2c81 |
return;
|
|
Fabiano Fidêncio |
32f2c81 |
}
|
|
Fabiano Fidêncio |
32f2c81 |
} else if (http_code == 200) {
|
|
Fabiano Fidêncio |
32f2c81 |
- DEBUG(SSSDBG_TRACE_INTERNAL, "Found %zu items\n", state->sec_key_list_len);
|
|
Fabiano Fidêncio |
32f2c81 |
ret = sec_list_parse(outbuf, state,
|
|
Fabiano Fidêncio |
32f2c81 |
&state->sec_key_list,
|
|
Fabiano Fidêncio |
32f2c81 |
&state->sec_key_list_len);
|
|
Fabiano Fidêncio |
32f2c81 |
@@ -215,6 +214,7 @@ static void sec_list_done(struct tevent_req *subreq)
|
|
Fabiano Fidêncio |
32f2c81 |
tevent_req_error(req, ret);
|
|
Fabiano Fidêncio |
32f2c81 |
return;
|
|
Fabiano Fidêncio |
32f2c81 |
}
|
|
Fabiano Fidêncio |
32f2c81 |
+ DEBUG(SSSDBG_TRACE_INTERNAL, "Found %zu items\n", state->sec_key_list_len);
|
|
Fabiano Fidêncio |
32f2c81 |
} else {
|
|
Fabiano Fidêncio |
32f2c81 |
tevent_req_error(req, http2errno(http_code));
|
|
Fabiano Fidêncio |
32f2c81 |
return;
|
|
Fabiano Fidêncio |
32f2c81 |
--
|
|
Fabiano Fidêncio |
32f2c81 |
2.14.3
|
|
Fabiano Fidêncio |
32f2c81 |
|