summaryrefslogtreecommitdiff
path: root/ospfd
diff options
context:
space:
mode:
authorgdt <gdt>2004-12-09 14:51:03 +0000
committergdt <gdt>2004-12-09 14:51:03 +0000
commit91f3e525a95d6a86f916872116af162eb3bdae5d (patch)
treec9944157d5cde3acf11850420012814214f8488c /ospfd
parentf4436f7bb8234f86a1a38e2d8497b70a448a7246 (diff)
ospf_apiserver_term:
Remove unused variable. Add comment: this is seriously broken, and needs fixing. It appears likely to segfault if ever called. Comments please - should I make the fix I suggest in the comment? -gdt
Diffstat (limited to 'ospfd')
-rw-r--r--ospfd/ChangeLog6
-rw-r--r--ospfd/ospf_apiserver.c7
2 files changed, 12 insertions, 1 deletions
diff --git a/ospfd/ChangeLog b/ospfd/ChangeLog
index 77f6899f..afa92c71 100644
--- a/ospfd/ChangeLog
+++ b/ospfd/ChangeLog
@@ -1,3 +1,9 @@
+2004-12-09 Greg Troxel <gdt@fnord.ir.bbn.com>
+
+ * ospf_apiserver.c (ospf_apiserver_term): Remove unused variable
+ nnode to fix warning.
+ (ospf_apiserver_term): add comment about obviously wrong code.
+
2004-12-08 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
* *.c: Change level of debug messages to LOG_DEBUG.
diff --git a/ospfd/ospf_apiserver.c b/ospfd/ospf_apiserver.c
index 4f294f71..07b8f211 100644
--- a/ospfd/ospf_apiserver.c
+++ b/ospfd/ospf_apiserver.c
@@ -180,7 +180,7 @@ out:
void
ospf_apiserver_term (void)
{
- struct listnode *node, *nnode;
+ struct listnode *node;
struct ospf_apiserver *apiserv;
/* Unregister wildcard [0/0] type */
@@ -189,6 +189,11 @@ ospf_apiserver_term (void)
/* Free all client instances */
while ( (node = listhead (apiserver_list)) != NULL)
+ /*
+ * XXX: this is just plain odd/wrong. Is there a missing
+ * apiserv = (struct ospf_apiserver *) node;
+ * ?
+ */
ospf_apiserver_free (apiserv);
/* Free client list itself */