Skip to contentSkip to conversation

ax25: Fix set-but-unused variable.

PATCH In review David Miller 1 participant 1 message Apr 18, 2011

Subsystems (2)
lore
Share & tools
lore

David Miller

author maintainer
#0 lore raw

PATCH 8/42 ax25: Fix set-but-unused variable.

The variable 's' is set but unused in ax25_protocol_release(). Just kill it off.

---
 net/ax25/ax25_iface.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
net/ax25/ax25_iface.c +1 -2
index 5a0dda8..60b545e 100644
@@ -58,7 +58,7 @@ EXPORT_SYMBOL_GPL(ax25_register_pid);
 
 void ax25_protocol_release(unsigned int pid)
 {
-	struct ax25_protocol *s, *protocol;
+	struct ax25_protocol *protocol;
 
 	write_lock_bh(&protocol_list_lock);
 	protocol = protocol_list;
@@ -72,7 +72,6 @@ void ax25_protocol_release(unsigned int pid)
 
 	while (protocol != NULL && protocol->next != NULL) {
 		if (protocol->next->pid == pid) {
-			s = protocol->next;
 			protocol->next = protocol->next->next;
 			goto out;
 		}
Signature · 1 line
1.7.4.3