mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Fixed a crash when trying to delete a channel that is being used by a timer
This commit is contained in:
parent
85ae27e372
commit
12308b3c29
1
HISTORY
1
HISTORY
@ -8843,3 +8843,4 @@ Video Disk Recorder Revision History
|
|||||||
same thread. This fixes possible crashes when moving or deleting channels in
|
same thread. This fixes possible crashes when moving or deleting channels in
|
||||||
the menu or through SVDRP (as well as other operations that try to acquire a
|
the menu or through SVDRP (as well as other operations that try to acquire a
|
||||||
read lock within a write lock).
|
read lock within a write lock).
|
||||||
|
- Fixed a crash when trying to delete a channel that is being used by a timer.
|
||||||
|
3
menu.c
3
menu.c
@ -4,7 +4,7 @@
|
|||||||
* See the main source file 'vdr.c' for copyright information and
|
* See the main source file 'vdr.c' for copyright information and
|
||||||
* how to reach the author.
|
* how to reach the author.
|
||||||
*
|
*
|
||||||
* $Id: menu.c 4.13 2015/09/16 11:02:33 kls Exp $
|
* $Id: menu.c 4.14 2016/12/08 10:39:29 kls Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "menu.h"
|
#include "menu.h"
|
||||||
@ -498,6 +498,7 @@ eOSState cMenuChannels::Delete(void)
|
|||||||
int DeletedChannel = Channel->Number();
|
int DeletedChannel = Channel->Number();
|
||||||
// Check if there is a timer using this channel:
|
// Check if there is a timer using this channel:
|
||||||
if (Timers->UsesChannel(Channel)) {
|
if (Timers->UsesChannel(Channel)) {
|
||||||
|
channelsStateKey.Remove(false);
|
||||||
Skins.Message(mtError, tr("Channel is being used by a timer!"));
|
Skins.Message(mtError, tr("Channel is being used by a timer!"));
|
||||||
return osContinue;
|
return osContinue;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user