summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2017-07-31 10:03:59 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2017-07-31 10:03:59 +0900
commit573d0cf586573a1c9907b45a791f4289ddc7a11c (patch)
tree8274ef2f029ca659fdf1d6df59311b9f6264efef
parentae79052376c516fbd836cea08a2187cf26049aea (diff)
eina debug - set length after freeing/iterating over the keys
found by PVS studio
-rw-r--r--src/lib/eina/eina_debug.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/eina/eina_debug.c b/src/lib/eina/eina_debug.c
index 692a2ed738..f0d101e864 100644
--- a/src/lib/eina/eina_debug.c
+++ b/src/lib/eina/eina_debug.c
@@ -401,10 +401,10 @@ _opcodes_unregister_all(Eina_Debug_Session *session)
401 _opcode_reply_info *info = NULL; 401 _opcode_reply_info *info = NULL;
402 402
403 if (!session) return; 403 if (!session) return;
404 session->cbs_length = 0;
405 for (i = 0; i < session->cbs_length; i++) 404 for (i = 0; i < session->cbs_length; i++)
406 eina_list_free(session->cbs[i]); 405 eina_list_free(session->cbs[i]);
407 free(session->cbs); 406 free(session->cbs);
407 session->cbs_length = 0;
408 session->cbs = NULL; 408 session->cbs = NULL;
409 409
410 EINA_LIST_FOREACH(session->opcode_reply_infos, l, info) 410 EINA_LIST_FOREACH(session->opcode_reply_infos, l, info)