summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimo Eskola <timo@tolleri.net>2018-09-05 19:36:41 +0300
committerTimo Eskola <timo@tolleri.net>2018-09-05 19:36:41 +0300
commit98ed156cd1cee59249df489c117cfbe12a84c0d3 (patch)
tree9a5336386aeac1cd9e61f9b519a10aa5e02a6241
parentbad9290d3d3cfd335fca6ac38d5eefbee976b33e (diff)
downloadvdr-plugin-duplicates-98ed156cd1cee59249df489c117cfbe12a84c0d3.tar.gz
vdr-plugin-duplicates-98ed156cd1cee59249df489c117cfbe12a84c0d3.tar.bz2
Fixed newly intorduced locking order issue.
-rw-r--r--menu.c21
1 files changed, 10 insertions, 11 deletions
diff --git a/menu.c b/menu.c
index 348f4de..5fd9dfe 100644
--- a/menu.c
+++ b/menu.c
@@ -69,18 +69,17 @@ cMenuDuplicate::cMenuDuplicate(const cRecording *Recording)
}
#if VDRVERSNUM >= 20301
-bool cMenuDuplicate::RefreshRecording(void)
-{
+bool cMenuDuplicate::RefreshRecording(void) {
if (const cRecordings *Recordings = cRecordings::GetRecordingsRead(recordingsStateKey)) {
- if ((recording = Recordings->GetByName(originalFileName)) != NULL)
- Display();
- else {
- recordingsStateKey.Remove();
- Skins.Message(mtWarning, trVDR("Recording vanished!"));
- return false;
- }
- recordingsStateKey.Remove();
- }
+ if ((recording = Recordings->GetByName(originalFileName)) != NULL) {
+ recordingsStateKey.Remove();
+ Display();
+ } else {
+ recordingsStateKey.Remove();
+ Skins.Message(mtWarning, trVDR("Recording vanished!"));
+ return false;
+ }
+ }
return true;
}
#endif