From 3013374988b2206517075ca24c66b773dff51d79 Mon Sep 17 00:00:00 2001 From: Jon Trulson Date: Fri, 26 Dec 2014 16:00:55 -0700 Subject: [PATCH] csa: Coverity (memory corruption, moderate) --- cde/lib/csa/agent.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cde/lib/csa/agent.c b/cde/lib/csa/agent.c index bbae64cb..ba5108e6 100644 --- a/cde/lib/csa/agent.c +++ b/cde/lib/csa/agent.c @@ -481,11 +481,13 @@ _DtCm_handle_callback() prev->next = ptr->next; _FreeCallbackInfo(ptr); + ptr = NULL; /* freed by _FreeCallbackInfo() */ } else { prev = ptr; } - ptr = ptr->next; + if (ptr) + ptr = ptr->next; } cb_tail = prev; } -- 2.25.1