diff options
author | Dave Wallace <dwallacelf@gmail.com> | 2017-07-03 13:11:38 -0400 |
---|---|---|
committer | Dave Wallace <dwallacelf@gmail.com> | 2017-07-17 21:00:52 -0400 |
commit | d756b35032cdf7fdaaf0d6611388a54d32d72e92 (patch) | |
tree | 21c9626d87fde1c935755862811b339dc7338ad1 /src/svm/svmdb.c | |
parent | 365a2b851024080c2f8f59bce2b61f243a85c254 (diff) |
Fix unlinking of /dev/shm files.
- api-segment prefix not used when unlinking shm files
- unlink root region on exit if no clients referenced
- stale reference to freed segment name
- don't add fake client to /db unless CLIB_DEBUG > 2
- turn off the gmond plugin
- clean up unused vars in vpp/api
Change-Id: I66451fcfd6ee64a12466c2d6c209050e3cdb74b7
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'src/svm/svmdb.c')
-rw-r--r-- | src/svm/svmdb.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/src/svm/svmdb.c b/src/svm/svmdb.c index 03dfe7c33d3..043b0924d84 100644 --- a/src/svm/svmdb.c +++ b/src/svm/svmdb.c @@ -106,11 +106,16 @@ svmdb_map (svmdb_map_args_t * dba) } /* Nope, it's our problem... */ - /* Add a bogus client (pid=0) so the svm won't be deallocated */ - oldheap = svm_push_pvt_heap (db_rp); - vec_add1 (client->db_rp->client_pids, 0); - svm_pop_heap (oldheap); - + if (CLIB_DEBUG > 2) + { + /* Add a bogus client (pid=0) so the svm won't be deallocated */ + clib_warning + ("[%d] adding fake client (pid=0) so '%s' won't be unlinked", + getpid (), db_rp->region_name); + oldheap = svm_push_pvt_heap (db_rp); + vec_add1 (client->db_rp->client_pids, 0); + svm_pop_heap (oldheap); + } oldheap = svm_push_data_heap (db_rp); vec_validate (hp, 0); |