Commit fe6e7e3d authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Record: escape file names

Close #7490
parent 7e04b2c2
......@@ -312,17 +312,24 @@ static int OutputNew( sout_stream_t *p_stream,
const char *psz_muxer, const char *psz_prefix, const char *psz_extension )
{
sout_stream_sys_t *p_sys = p_stream->p_sys;
char *psz_file = NULL;
char *psz_file = NULL, *psz_tmp = NULL;
char *psz_output = NULL;
int i_count;
if( asprintf( &psz_file, "%s%s%s",
if( asprintf( &psz_tmp, "%s%s%s",
psz_prefix, psz_extension ? "." : "", psz_extension ? psz_extension : "" ) < 0 )
{
psz_file = NULL;
goto error;
}
psz_file = config_StringEscape( psz_tmp );
if( !psz_file )
{
free( psz_tmp );
goto error;
}
free( psz_tmp );
if( asprintf( &psz_output, "std{access=file,mux='%s',dst='%s'}",
psz_muxer, psz_file ) < 0 )
{
......
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