Commit f59cd97b authored by Gildas Bazin's avatar Gildas Bazin

* The configuration file and the log file are opened in text mode. This mode
should only have a meaning on Win32 and isn't supposed to break any other
platform. If does give you any trouble then shout.
parent a833d9d8
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* logger.c : file logging plugin for vlc * logger.c : file logging plugin for vlc
***************************************************************************** *****************************************************************************
* Copyright (C) 2002 VideoLAN * Copyright (C) 2002 VideoLAN
* $Id: logger.c,v 1.7 2002/04/21 11:23:03 gbazin Exp $ * $Id: logger.c,v 1.8 2002/05/01 21:31:53 gbazin Exp $
* *
* Authors: Samuel Hocevar <sam@zoy.org> * Authors: Samuel Hocevar <sam@zoy.org>
* *
...@@ -127,7 +127,7 @@ static int intf_Open( intf_thread_t *p_intf ) ...@@ -127,7 +127,7 @@ static int intf_Open( intf_thread_t *p_intf )
/* Open the log file and remove any buffering for the stream */ /* Open the log file and remove any buffering for the stream */
intf_WarnMsg( 1, "intf: opening logfile `%s'", psz_filename ); intf_WarnMsg( 1, "intf: opening logfile `%s'", psz_filename );
p_intf->p_sys->p_file = fopen( psz_filename, "w" ); p_intf->p_sys->p_file = fopen( psz_filename, "wt" );
setvbuf( p_intf->p_sys->p_file, NULL, _IONBF, 0 ); setvbuf( p_intf->p_sys->p_file, NULL, _IONBF, 0 );
p_intf->p_sys->p_sub = intf_MsgSub(); p_intf->p_sys->p_sub = intf_MsgSub();
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* configuration.c management of the modules configuration * configuration.c management of the modules configuration
***************************************************************************** *****************************************************************************
* Copyright (C) 2001 VideoLAN * Copyright (C) 2001 VideoLAN
* $Id: configuration.c,v 1.20 2002/04/24 23:08:08 gbazin Exp $ * $Id: configuration.c,v 1.21 2002/05/01 21:31:53 gbazin Exp $
* *
* Authors: Gildas Bazin <gbazin@netcourrier.com> * Authors: Gildas Bazin <gbazin@netcourrier.com>
* *
...@@ -363,7 +363,7 @@ int config_LoadConfigFile( const char *psz_module_name ) ...@@ -363,7 +363,7 @@ int config_LoadConfigFile( const char *psz_module_name )
intf_WarnMsg( 5, "config: opening config file %s", psz_filename ); intf_WarnMsg( 5, "config: opening config file %s", psz_filename );
file = fopen( psz_filename, "r" ); file = fopen( psz_filename, "rt" );
if( !file ) if( !file )
{ {
intf_WarnMsg( 1, "config: couldn't open config file %s for reading (%s)", intf_WarnMsg( 1, "config: couldn't open config file %s for reading (%s)",
...@@ -551,7 +551,7 @@ int config_SaveConfigFile( const char *psz_module_name ) ...@@ -551,7 +551,7 @@ int config_SaveConfigFile( const char *psz_module_name )
intf_WarnMsg( 5, "config: opening config file %s", psz_filename ); intf_WarnMsg( 5, "config: opening config file %s", psz_filename );
file = fopen( psz_filename, "r" ); file = fopen( psz_filename, "rt" );
if( !file ) if( !file )
{ {
intf_WarnMsg( 1, "config: couldn't open config file %s for reading (%s)", intf_WarnMsg( 1, "config: couldn't open config file %s for reading (%s)",
...@@ -631,7 +631,7 @@ int config_SaveConfigFile( const char *psz_module_name ) ...@@ -631,7 +631,7 @@ int config_SaveConfigFile( const char *psz_module_name )
* Save module config in file * Save module config in file
*/ */
file = fopen( psz_filename, "w" ); file = fopen( psz_filename, "wt" );
if( !file ) if( !file )
{ {
intf_WarnMsg( 1, "config: couldn't open config file %s for writing", intf_WarnMsg( 1, "config: couldn't open config file %s for writing",
......
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