cannot delete msg in handleLowerMsg()

11 views
Skip to first unread message

Saneeha Ahmed

unread,
Aug 21, 2014, 5:01:14 PM8/21/14
to omnetpp
Dear all,
I sent this question before. I am still facing some problems. The issue is that I cannot delete my own application layer packets in handleLowerMsg, by using delete(msg) at the end . My packet contains some structures and arrays. However, this should not be the reason , as I could delete messages when encapsulated as WaveShortMessage(). As I no longer want to encapsulate my application layer packet into WaveShortMessage(); I am not using any encapsulation in my code. All I am doing is to dynamic_cast incoming message into a packet of my packet type and then using this packet throughout handleLowerMsg().Before exiting handleLowerMsg() I am putting delete(msg) and the application crashes, after sending just one message.

Can any one please suggest what should be checked.

Thanks and Regards
Saneeha

Reply all
Reply to author
Forward
0 new messages