mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-31 01:11:12 +02:00
PMT_CHANGED: fix use after delete
This commit is contained in:
@@ -1141,6 +1141,7 @@ void CRCInput::getMsg_us(neutrino_msg_t * msg, neutrino_msg_data_t * data, uint6
|
||||
case CZapitClient::EVT_PMT_CHANGED:
|
||||
*msg = NeutrinoMessages::EVT_PMT_CHANGED;
|
||||
*data = (neutrino_msg_data_t) p;
|
||||
dont_delete_p = true;
|
||||
break;
|
||||
case CZapitClient::EVT_TUNE_COMPLETE:
|
||||
*msg = NeutrinoMessages::EVT_TUNE_COMPLETE;
|
||||
|
@@ -3762,6 +3762,7 @@ int CNeutrinoApp::handleMsg(const neutrino_msg_t _msg, neutrino_msg_data_t data)
|
||||
else if( msg == NeutrinoMessages::EVT_PMT_CHANGED) {
|
||||
t_channel_id channel_id = *(t_channel_id*) data;
|
||||
CRecordManager::getInstance()->Update(channel_id);
|
||||
delete[] (unsigned char*) data;
|
||||
return messages_return::handled;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user