Skip to contentSkip to conversation

client: remove unneeded initialization

PATCH In review James Prestwood 2 participants 6 messages Mar 4, 2024

lore
Share & tools
lore
#0 lore raw

PATCH 1/5 client: remove unneeded initialization

---
 client/display.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
client/display.c +1 -1
index 83214c86..f0f3282a 100644
@@ -194,7 +194,7 @@ void display_refresh_set_cmd(const char *family, const char *entity,
 
 		for (i = 0; i < argc; i++) {
 			bool needs_quotes = false;
-			char *p = argv[i];
+			char *p;
 
 			for (p = argv[i]; *p != '\0'; p++) {
 				if (*p != ' ')
Signature · 1 line
2.34.1
#1 lore raw

PATCH 2/5 ie: remove unneeded initialization

---
 src/ie.c | 3 ---
 1 file changed, 3 deletions(-)
src/ie.c +0 -3
index a51724aa..86f33f2a 100644
@@ -1178,9 +1178,6 @@ static int build_ciphers_common(const struct ie_rsn_info *info, uint8_t *to,
 	countptr = to + pos;
 	pos += 2;
 
-	akm_suite = IE_RSN_AKM_SUITE_8021X;
-	count = 0;
-
 	for (count = 0, akm_suite = IE_RSN_AKM_SUITE_8021X;
 			akm_suite <= IE_RSN_AKM_SUITE_OSEN;
 				akm_suite <<= 1) {
Signature · 1 line
2.34.1
#2 lore raw

PATCH 3/5 files: remove unneeded initialization

In reply to James Prestwood
---
 src/fils.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
src/fils.c +1 -1
index f876e7e5..ff8c1d6c 100644
@@ -489,7 +489,7 @@ static int fils_rx_associate(struct auth_proto *driver, const uint8_t *frame,
 	bool sha384 = (fils->hs->akm_suite & (IE_RSN_AKM_SUITE_FILS_SHA384 |
 			IE_RSN_AKM_SUITE_FT_OVER_FILS_SHA384));
 	uint8_t data[44];
-	uint8_t *ptr = data;
+	uint8_t *ptr;
 
 	if (assoc->status_code != 0)
 		return L_CPU_TO_LE16(assoc->status_code);
Signature · 1 line
2.34.1
#3 lore raw

PATCH 4/5 eap-mschapv2: remove unneeded initialization

In reply to James Prestwood
---
 src/eap-mschapv2.c | 1 -
 1 file changed, 1 deletion(-)
src/eap-mschapv2.c +0 -1
index 7f71cc82..1639f578 100644
@@ -445,7 +445,6 @@ static int eap_mschapv2_check_settings(struct l_settings *settings,
 	if (!identity) {
 		secret = l_queue_find(secrets, eap_secret_info_match, setting);
 		if (secret) {
-			identity = l_strdup(secret->value);
 			password = l_strdup(secret->value +
 						strlen(secret->value) + 1);
 
Signature · 1 line
2.34.1
#4 lore raw

PATCH 5/5 dpp: check wrapped data exists in authenticate response

In reply to James Prestwood
---
 src/dpp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
src/dpp.c +1 -1
index 74b4c2bc..567fe8d2 100644
@@ -2368,7 +2368,7 @@ static void authenticate_response(struct dpp_sm *dpp, const uint8_t *from,
 		}
 	}
 
-	if (status != DPP_STATUS_OK || !r_boot_hash || !r_proto ) {
+	if (status != DPP_STATUS_OK || !r_boot_hash || !r_proto || !wrapped) {
 		l_debug("Auth response bad status or missing attributes");
 		return;
 	}
Signature · 1 line
2.34.1