Commit 1d5ecc23 authored by Gildas Bazin's avatar Gildas Bazin

* src/libvlc.c: fixed the "color" config option.
* src/misc/messages.c: removed an unnecessary #ifdef WIN32 in PrintMsg().
parent d9ca68f7
......@@ -2,7 +2,7 @@
* libvlc.c: main libvlc source
*****************************************************************************
* Copyright (C) 1998-2002 VideoLAN
* $Id: libvlc.c,v 1.77 2003/04/08 08:35:59 massiot Exp $
* $Id: libvlc.c,v 1.78 2003/04/09 19:58:25 gbazin Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
......@@ -155,7 +155,7 @@ int VLC_Create( void )
psz_env = getenv( "VLC_VERBOSE" );
libvlc.i_verbose = psz_env ? atoi( psz_env ) : -1;
#ifdef HAVE_ISATTY
#if defined( HAVE_ISATTY ) && !defined( WIN32 )
libvlc.b_color = isatty( 2 ); /* 2 is for stderr */
#else
libvlc.b_color = VLC_FALSE;
......@@ -435,7 +435,7 @@ int VLC_Init( int i_object, int i_argc, char *ppsz_argv[] )
libvlc.i_verbose = __MIN( i_tmp, 2 );
}
}
libvlc.b_color = libvlc.b_color || config_GetInt( p_vlc, "color" );
libvlc.b_color = libvlc.b_color && config_GetInt( p_vlc, "color" );
/*
* Output messages that may still be in the queue
......
......@@ -4,7 +4,7 @@
* modules, especially intf modules. See config.h for output configuration.
*****************************************************************************
* Copyright (C) 1998-2002 VideoLAN
* $Id: messages.c,v 1.29 2003/01/15 13:46:05 massiot Exp $
* $Id: messages.c,v 1.30 2003/04/09 19:58:25 gbazin Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
......@@ -408,20 +408,12 @@ static void FlushMsg ( msg_bank_t *p_bank )
*****************************************************************************/
static void PrintMsg ( vlc_object_t * p_this, msg_item_t * p_item )
{
#ifndef WIN32
# define COL(x) "\033[" #x ";1m"
# define RED COL(31)
# define GREEN COL(32)
# define YELLOW COL(33)
# define WHITE COL(37)
# define GRAY "\033[0m"
#else
# define RED ""
# define GREEN ""
# define YELLOW ""
# define WHITE ""
# define GRAY ""
#endif
#ifdef UNDER_CE
int i_dummy;
......
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