Module: sip-router Branch: 3.2 Commit: 231017d40132dd2d2e21d715d12101ed67b51d45 URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=231017d4...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: Wed Jun 13 11:51:57 2012 +0200
drouting: reset the content of routing tree if root pointer is not freed
- reported by Yufei Tao (cherry picked from commit c737ff95bb2e742981d81088169baa60d4605b85)
---
modules_k/drouting/routing.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/modules_k/drouting/routing.c b/modules_k/drouting/routing.c index 1ff7629..f54709e 100644 --- a/modules_k/drouting/routing.c +++ b/modules_k/drouting/routing.c @@ -460,7 +460,8 @@ free_rt_data( shm_free(rt_data->noprefix.rg); rt_data->noprefix.rg = 0; } - /* del top level */ + /* del top level or reset to 0 it's content */ if (all) shm_free(rt_data); + else memset(rt_data, 0, sizeof(rt_data_t)); } }