diff options
author | Thomas Tsou <tom@tsou.cc> | 2013-10-15 16:18:58 -0400 |
---|---|---|
committer | Thomas Tsou <tom@tsou.cc> | 2013-10-18 13:10:18 -0400 |
commit | de1648ca6b21118eb947cd33e643e93a4c56542e (patch) | |
tree | a89da0f05ee861e493305c4e8b3d840d89441640 /Transceiver52M/radioInterfaceResamp.cpp | |
parent | 3952d80d057eb3c8c63c4661489581405cf0c87c (diff) |
Transceiver52M: Deallocate high level resources on shutdown
This primarily addresses the error case at initialization.
In the event that the transceiver fails to start, we should
be able cleanly shutdown and release while providing a useful
reason for exiting.
After the radio is started and threads launched, there
are no thread state variables or shutdown messaging between
threads, and the transceiver cannot be consistently
shutdown. This issue remains to be solved.
Signed-off-by: Thomas Tsou <tom@tsou.cc>
Diffstat (limited to 'Transceiver52M/radioInterfaceResamp.cpp')
-rw-r--r-- | Transceiver52M/radioInterfaceResamp.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Transceiver52M/radioInterfaceResamp.cpp b/Transceiver52M/radioInterfaceResamp.cpp index c3b4396..6c3839a 100644 --- a/Transceiver52M/radioInterfaceResamp.cpp +++ b/Transceiver52M/radioInterfaceResamp.cpp @@ -75,8 +75,6 @@ RadioInterfaceResamp::~RadioInterfaceResamp() void RadioInterfaceResamp::close() { - RadioInterface::close(); - delete innerSendBuffer; delete outerSendBuffer; delete innerRecvBuffer; @@ -89,9 +87,13 @@ void RadioInterfaceResamp::close() outerSendBuffer = NULL; innerRecvBuffer = NULL; outerRecvBuffer = NULL; + sendBuffer = NULL; + recvBuffer = NULL; upsampler = NULL; dnsampler = NULL; + + RadioInterface::close(); } /* Initialize I/O specific objects */ |