Commit f88bf2c1 authored by Marian Durkovic's avatar Marian Durkovic

Add quotes to all VLM commands requested by VLM wx panel

parent 85e000fa
......@@ -52,7 +52,7 @@ void VLMStream::Disable()
void VLMStream::Delete()
{
vlm_message_t *message;
string command = "del " + string( p_media->psz_name );
string command = "del \"" + string( p_media->psz_name ) + "\"";
/* FIXME: Should be moved to vlm_Wrapper */
vlm_ExecuteCommand( p_vlm->GetVLM(), (char*)command.c_str(), & message );
vlm_MessageDelete( message );
......@@ -74,7 +74,7 @@ VLMBroadcastStream::~VLMBroadcastStream()
void VLMBroadcastStream::Play()
{
vlm_message_t *message;
string command = "control " + string( p_media->psz_name ) + " play";
string command = "control \"" + string( p_media->psz_name ) + "\" play";
/* FIXME: Should be moved to vlm_Wrapper */
vlm_ExecuteCommand( p_vlm->GetVLM(), (char*)command.c_str(), & message );
vlm_MessageDelete( message );
......@@ -83,7 +83,7 @@ void VLMBroadcastStream::Play()
void VLMBroadcastStream::Stop()
{
vlm_message_t *message;
string command = "control " + string( p_media->psz_name ) + " stop";
string command = "control \"" + string( p_media->psz_name ) + "\" stop";
vlm_ExecuteCommand( p_vlm->GetVLM(), (char*)command.c_str(), & message );
vlm_MessageDelete( message );
}
......@@ -91,7 +91,7 @@ void VLMBroadcastStream::Stop()
void VLMBroadcastStream::Pause()
{
vlm_message_t *message;
string command = "control " + string( p_media->psz_name ) + " pause";
string command = "control \"" + string( p_media->psz_name ) + "\" pause";
vlm_ExecuteCommand( p_vlm->GetVLM(), (char*)command.c_str(), & message );
vlm_MessageDelete( message );
}
......
......@@ -60,7 +60,7 @@ void VLMWrapper::AddBroadcast( const char* name, const char* input,
vlc_bool_t b_enabled, vlc_bool_t b_loop )
{
vlm_message_t *message;
string command = "new " + string(name) + " broadcast";
string command = "new \"" + string(name) + "\" broadcast";
vlm_ExecuteCommand( p_vlm, command.c_str(), &message );
vlm_MessageDelete( message );
EditBroadcast( name, input, output, b_enabled, b_loop );
......@@ -72,27 +72,27 @@ void VLMWrapper::EditBroadcast( const char* name, const char* input,
{
vlm_message_t *message;
string command;
command = "setup " + string(name) + " inputdel all";
command = "setup \"" + string(name) + "\" inputdel all";
vlm_ExecuteCommand( p_vlm, command.c_str(), &message );
vlm_MessageDelete( message );
command = "setup " + string(name) + " input " + string(input);
command = "setup \"" + string(name) + "\" input \"" + string(input) + "\"";
vlm_ExecuteCommand( p_vlm, command.c_str(), &message );
vlm_MessageDelete( message );
if( strlen(output) > 0 )
{
command = "setup " + string(name) + " output " + string(output);
command = "setup \"" + string(name) + "\" output \"" + string(output) + "\"";
vlm_ExecuteCommand( p_vlm, (char*)command.c_str(), &message );
vlm_MessageDelete( message );
}
if( b_enabled )
{
command = "setup " + string(name) + " enabled";
command = "setup \"" + string(name) + "\" enabled";
vlm_ExecuteCommand( p_vlm, command.c_str(), &message );
vlm_MessageDelete( message );
}
if( b_loop )
{
command = "setup " + string(name) + " loop";
command = "setup \"" + string(name) + "\" loop";
vlm_ExecuteCommand( p_vlm, command.c_str(), &message );
vlm_MessageDelete( message );
}
......@@ -103,7 +103,7 @@ void VLMWrapper::AddVod( const char* name, const char* input,
vlc_bool_t b_enabled, vlc_bool_t b_loop )
{
vlm_message_t *message;
string command = "new " + string(name) + " vod";
string command = "new \"" + string(name) + "\" vod";
vlm_ExecuteCommand( p_vlm, command.c_str(), &message );
vlm_MessageDelete( message );
EditVod( name, input, output, b_enabled, b_loop );
......@@ -115,18 +115,18 @@ void VLMWrapper::EditVod( const char* name, const char* input,
{
vlm_message_t *message;
string command;
command = "setup " + string(name) + " input " + string(input);
command = "setup \"" + string(name) + "\" input \"" + string(input) + "\"";
vlm_ExecuteCommand( p_vlm, command.c_str(), &message );
vlm_MessageDelete( message );
if( strlen(output) > 0 )
{
command = "setup " + string(name) + " output " + string(output);
command = "setup \"" + string(name) + "\" output \"" + string(output) + "\"";
vlm_ExecuteCommand( p_vlm, (char*)command.c_str(), &message );
vlm_MessageDelete( message );
}
if( b_enabled )
{
command = "setup " + string(name) + " enabled";
command = "setup \"" + string(name) + "\" enabled";
vlm_ExecuteCommand( p_vlm, command.c_str(), &message );
vlm_MessageDelete( message );
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment