summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBeniamino Galvani <bgalvani@redhat.com>2018-06-23 14:46:00 +0200
committerBeniamino Galvani <bgalvani@redhat.com>2018-06-23 14:46:59 +0200
commite86417789a370c926aa2fc54edd467a921f72959 (patch)
tree1fdb47d82619e8414155eba926e5890ec755cbb8
parent2576e3a8e886c6ac216392efc84ac18d1b148df8 (diff)
downloadNetworkManager-bg/802-1x-hints.tar.gz
clients: fix asking 802.1X secretsbg/802-1x-hints
request->hints is never NULL, also check if there are any elements. Fixes: 1a6e53808db8bb8e75317fd5feacd74a9a98860f
-rw-r--r--clients/common/nm-secret-agent-simple.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/clients/common/nm-secret-agent-simple.c b/clients/common/nm-secret-agent-simple.c
index 1468f0f335..9c605d632f 100644
--- a/clients/common/nm-secret-agent-simple.c
+++ b/clients/common/nm-secret-agent-simple.c
@@ -218,7 +218,7 @@ add_8021x_secrets (NMSecretAgentSimpleRequest *request,
NMSecretAgentSimpleSecret *secret;
/* If hints are given, then always ask for what the hints require */
- if (request->hints) {
+ if (request->hints && request->hints[0]) {
char **iter;
for (iter = request->hints; *iter; iter++) {
secret = nm_secret_agent_simple_secret_new (NM_SECRET_AGENT_SECRET_TYPE_SECRET,