/*****************************************************************************
* file.c
*****************************************************************************
- * Copyright (C) 2001, 2002 VideoLAN
+ * Copyright (C) 2001, 2002 the VideoLAN team
* $Id$
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
#ifndef STDOUT_FILENO
# define STDOUT_FILENO 1
#endif
+#ifndef O_LARGEFILE
+# define O_LARGEFILE 0
+#endif
/*****************************************************************************
* Module descriptor
static void Close( vlc_object_t * );
#define SOUT_CFG_PREFIX "sout-file-"
+#define APPEND_TEXT N_("Append to file")
+#define APPEND_LONGTEXT N_( "Append to file if it exists instead " \
+ "of replacing it.")
vlc_module_begin();
- set_description( _("File stream ouput") );
+ set_description( _("File stream output") );
+ set_shortname( N_("File" ));
set_capability( "sout access", 50 );
+ set_category( CAT_SOUT );
+ set_subcategory( SUBCAT_SOUT_ACO );
add_shortcut( "file" );
add_shortcut( "stream" );
- add_bool( SOUT_CFG_PREFIX "append", 0, NULL, "append", "", VLC_TRUE );
+ add_bool( SOUT_CFG_PREFIX "append", 0, NULL, APPEND_TEXT,APPEND_LONGTEXT,
+ VLC_TRUE );
set_callbacks( Open, Close );
vlc_module_end();
int i_flags;
vlc_value_t val;
- sout_ParseCfg( p_access, SOUT_CFG_PREFIX, ppsz_sout_options, p_access->p_cfg );
+ sout_CfgParse( p_access, SOUT_CFG_PREFIX, ppsz_sout_options, p_access->p_cfg );
if( !( p_access->p_sys = malloc( sizeof( sout_access_out_sys_t ) ) ) )
{
msg_Err( p_access, "no file name specified" );
return VLC_EGENERIC;
}
- i_flags = O_RDWR|O_CREAT;
+ i_flags = O_RDWR|O_CREAT|O_LARGEFILE;
var_Get( p_access, SOUT_CFG_PREFIX "append", &val );
if( val.b_bool )