1
0
mirror of https://github.com/VDR4Arch/vdr.git synced 2023-10-10 13:36:52 +02:00

Fixed displaying the error log message in case an unknown plugin was requested in a key macro

This commit is contained in:
Klaus Schmidinger 2006-10-14 10:06:16 +02:00
parent 6a15d77429
commit 7bed3fd6ba
3 changed files with 18 additions and 11 deletions

View File

@ -1827,6 +1827,8 @@ Petri Hintukainen <Petri.Hintukainen@hut.fi>
.update file after the last NeedsUpdate() check
for fixing a possible crash if cPluginManager::GetPlugin() is called with a NULL
pointer
for fixing displaying the error log message in case an unknown plugin was requested
in a key macro
Marcel Schaeben <mts280@gmx.de>
for his "Easy Input" patch

View File

@ -4958,3 +4958,5 @@ Video Disk Recorder Revision History
- Updated the Hungarian language texts (thanks to Guido Josten).
- Fixed a possible crash if cPluginManager::GetPlugin() is called with a NULL
pointer (thanks to Petri Hintukainen).
- Fixed displaying the error log message in case an unknown plugin was requested
in a key macro (thanks to Petri Hintukainen).

9
vdr.c
View File

@ -22,7 +22,7 @@
*
* The project's page is at http://www.cadsoft.de/vdr
*
* $Id: vdr.c 1.279 2006/09/01 12:57:44 kls Exp $
* $Id: vdr.c 1.280 2006/10/14 10:01:32 kls Exp $
*/
#include <getopt.h>
@ -923,17 +923,20 @@ int main(int argc, char *argv[])
case kCommands: DirectMainFunction(osCommands); break;
case kUser1 ... kUser9: cRemote::PutMacro(key); key = kNone; break;
case k_Plugin: {
const char *PluginName = cRemote::GetPlugin();
if (PluginName) {
DELETE_MENU;
if (cControl::Control())
cControl::Control()->Hide();
cPlugin *plugin = cPluginManager::GetPlugin(cRemote::GetPlugin());
cPlugin *plugin = cPluginManager::GetPlugin(PluginName);
if (plugin) {
Menu = plugin->MainMenuAction();
if (Menu)
Menu->Show();
}
else
esyslog("ERROR: unknown plugin '%s'", cRemote::GetPlugin());
esyslog("ERROR: unknown plugin '%s'", PluginName);
}
key = kNone; // nobody else needs to see these keys
}
break;