diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/alloc/AllocTest.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/alloc/AllocTest.cpp b/tests/alloc/AllocTest.cpp index f6170058..ac67ce95 100644 --- a/tests/alloc/AllocTest.cpp +++ b/tests/alloc/AllocTest.cpp @@ -539,12 +539,16 @@ static GprsMs *alloc_tbfs(BTS *the_bts, GprsMs *ms, unsigned ms_class, case TEST_MODE_DL_AFTER_UL: case TEST_MODE_UL_AFTER_DL: tbf_free(tbf); + tbf = NULL; break; default: break; } + if (!ms && tbf) + tbf_free(tbf); + return guard2.is_idle() ? NULL : ms; } |