start SCRIPTs with-my_system

Origin commit data
------------------
Branch: ni/coolstream
Commit: 3389defb17
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2012-09-11 (Tue, 11 Sep 2012)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Jacek Jendrzej
2012-09-11 20:33:34 +02:00
parent 67c5d7c91e
commit 41fbcb0970
6 changed files with 21 additions and 15 deletions

View File

@@ -40,13 +40,15 @@
#include <neutrino.h>
#include <gui/filebrowser.h>
#include <gui/movieplayer.h>
#include <gui/nfs.h>
#include <gui/widget/hintbox.h>
#include <gui/widget/messagebox.h>
#include <gui/widget/mountchooser.h>
#include <daemonc/remotecontrol.h>
#include <system/setting_helpers.h>
#include <system/fsmounter.h>
#include <gui/nfs.h>
#include <system/helpers.h>
#include <driver/record.h>
#include <zapit/capmt.h>
@@ -1452,7 +1454,7 @@ bool CRecordManager::RunStartScript(void)
return false;
puts("[neutrino.cpp] executing " NEUTRINO_RECORDING_START_SCRIPT ".");
if (system(NEUTRINO_RECORDING_START_SCRIPT) != 0) {
if (my_system(NEUTRINO_RECORDING_START_SCRIPT,NULL,NULL) != 0) {
perror(NEUTRINO_RECORDING_START_SCRIPT " failed");
return false;
}
@@ -1466,7 +1468,7 @@ bool CRecordManager::RunStopScript(void)
return false;
puts("[neutrino.cpp] executing " NEUTRINO_RECORDING_ENDED_SCRIPT ".");
if (system(NEUTRINO_RECORDING_ENDED_SCRIPT) != 0) {
if (my_system(NEUTRINO_RECORDING_ENDED_SCRIPT,NULL,NULL) != 0) {
perror(NEUTRINO_RECORDING_ENDED_SCRIPT " failed");
return false;
}

View File

@@ -66,6 +66,7 @@
#include <gui/widget/stringinput_ext.h>
#include <system/settings.h>
#include <system/helpers.h>
#include <driver/screen_max.h>
#include <algorithm>
@@ -317,7 +318,7 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &actionKey)
g_Sectionsd->setPauseScanning(true);
puts("[audioplayer.cpp] executing " AUDIOPLAYER_START_SCRIPT ".");
if (system(AUDIOPLAYER_START_SCRIPT) != 0)
if (my_system(AUDIOPLAYER_START_SCRIPT,NULL,NULL) != 0)
perror("Datei " AUDIOPLAYER_START_SCRIPT " fehlt.Bitte erstellen, wenn gebraucht.\nFile " AUDIOPLAYER_START_SCRIPT " not found. Please create if needed.\n");
show();
@@ -329,7 +330,7 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &actionKey)
m_frameBuffer->paintBackground();
puts("[audioplayer.cpp] executing " AUDIOPLAYER_END_SCRIPT ".");
if (system(AUDIOPLAYER_END_SCRIPT) != 0)
if (my_system(AUDIOPLAYER_END_SCRIPT,NULL,NULL) != 0)
perror("Datei " AUDIOPLAYER_END_SCRIPT " fehlt. Bitte erstellen, wenn gebraucht.\nFile " AUDIOPLAYER_END_SCRIPT " not found. Please create if needed.\n");
g_Zapit->unlockPlayBack();

View File

@@ -61,7 +61,7 @@
#ifndef NEW_LIBCURL
#include <curl/types.h>
#endif
#include <system/helpers.h>
#include <xmltree/xmlinterface.h>
#ifdef __USE_FILE_OFFSET64

View File

@@ -38,6 +38,7 @@
#include <gui/plugins.h>
#include <driver/screenshot.h>
#include <driver/volume.h>
#include <system/helpers.h>
#include <unistd.h>
#include <stdlib.h>
@@ -175,7 +176,7 @@ int CMoviePlayerGui::exec(CMenuTarget * parent, const std::string & actionKey)
startposition = 0;
puts("[movieplayer.cpp] executing " MOVIEPLAYER_START_SCRIPT ".");
if (system(MOVIEPLAYER_START_SCRIPT) != 0)
if (my_system(MOVIEPLAYER_START_SCRIPT,NULL,NULL) != 0)
perror(MOVIEPLAYER_START_SCRIPT " failed");
isMovieBrowser = false;
@@ -213,7 +214,7 @@ int CMoviePlayerGui::exec(CMenuTarget * parent, const std::string & actionKey)
bookmarkmanager->flush();
puts("[movieplayer.cpp] executing " MOVIEPLAYER_END_SCRIPT ".");
if (system(MOVIEPLAYER_END_SCRIPT) != 0)
if (my_system(MOVIEPLAYER_END_SCRIPT,NULL,NULL) != 0)
perror(MOVIEPLAYER_END_SCRIPT " failed");
CVFD::getInstance()->setMode(CVFD::MODE_TVRADIO);

View File

@@ -52,6 +52,7 @@
#include <gui/widget/progressbar.h>
#include <system/settings.h>
#include <system/helpers.h>
#include <global.h>
#include <neutrino.h>
@@ -248,7 +249,7 @@ int CScanTs::exec(CMenuTarget* /*parent*/, const std::string & actionKey)
if(!manual) {
g_RCInput->close_click();
if (system(NEUTRINO_SCAN_START_SCRIPT) != 0)
if (my_system(NEUTRINO_SCAN_START_SCRIPT,NULL,NULL) != 0)
perror(NEUTRINO_SCAN_START_SCRIPT " failed");
}
@@ -310,7 +311,7 @@ int CScanTs::exec(CMenuTarget* /*parent*/, const std::string & actionKey)
g_Zapit->stopScan();
if(!manual) {
if (system(NEUTRINO_SCAN_STOP_SCRIPT) != 0)
if (my_system(NEUTRINO_SCAN_STOP_SCRIPT,NULL,NULL) != 0)
perror(NEUTRINO_SCAN_STOP_SCRIPT " failed");
g_RCInput->open_click();
}

View File

@@ -96,6 +96,7 @@
#include <system/fsmounter.h>
#include <system/setting_helpers.h>
#include <system/settings.h>
#include <system/helpers.h>
#include <timerdclient/timerdmsg.h>
@@ -1745,7 +1746,7 @@ void wake_up( bool &wakeup)
if(!wakeup){
const char *neutrino_leave_deepstandby_script = CONFIGDIR "/deepstandby.off";
printf("[%s] executing %s\n",__FILE__ ,neutrino_leave_deepstandby_script);
if (system(neutrino_leave_deepstandby_script) != 0)
if (file_exists(neutrino_leave_deepstandby_script) && my_system(neutrino_leave_deepstandby_script,NULL,NULL) != 0)
perror( neutrino_leave_deepstandby_script );
}
#endif
@@ -2686,7 +2687,7 @@ _repeat:
return messages_return::handled;
}
else if( msg == NeutrinoMessages::ANNOUNCE_RECORD) {
system(NEUTRINO_RECORDING_TIMER_SCRIPT);
my_system(NEUTRINO_RECORDING_TIMER_SCRIPT,NULL,NULL);
if (g_settings.recording_type == RECORDING_FILE) {
char * recordingDir = ((CTimerd::RecordingInfo*)data)->recordingDir;
for(int i=0 ; i < NETWORK_NFS_NR_OF_ENTRIES ; i++) {
@@ -2946,7 +2947,7 @@ void CNeutrinoApp::ExitRun(const bool /*write_si*/, int retcode)
if(retcode) {
const char *neutrino_enter_deepstandby_script = CONFIGDIR "/deepstandby.on";
printf("[%s] executing %s\n",__FILE__ ,neutrino_enter_deepstandby_script);
if (system(neutrino_enter_deepstandby_script) != 0)
if (file_exists(neutrino_enter_deepstandby_script) && my_system(neutrino_enter_deepstandby_script,NULL,NULL) != 0)
perror(neutrino_enter_deepstandby_script );
printf("entering off state\n");
@@ -3224,7 +3225,7 @@ void CNeutrinoApp::standbyMode( bool bOnOff, bool fromDeepStandby )
standby_channel_id = CZapit::getInstance()->GetCurrentChannelID();
puts("[neutrino.cpp] executing " NEUTRINO_ENTER_STANDBY_SCRIPT ".");
if (system(NEUTRINO_ENTER_STANDBY_SCRIPT) != 0)
if (my_system(NEUTRINO_ENTER_STANDBY_SCRIPT,NULL,NULL) != 0)
perror(NEUTRINO_ENTER_STANDBY_SCRIPT " failed");
if(!CRecordManager::getInstance()->RecordingStatus())
@@ -3268,7 +3269,7 @@ void CNeutrinoApp::standbyMode( bool bOnOff, bool fromDeepStandby )
}
puts("[neutrino.cpp] executing " NEUTRINO_LEAVE_STANDBY_SCRIPT ".");
if (system(NEUTRINO_LEAVE_STANDBY_SCRIPT) != 0)
if (my_system(NEUTRINO_LEAVE_STANDBY_SCRIPT,NULL,NULL) != 0)
perror(NEUTRINO_LEAVE_STANDBY_SCRIPT " failed");
CVFD::getInstance()->setMode(CVFD::MODE_TVRADIO);