From 3007c6b8853dcac1d84cf978d1075d64e941a434 Mon Sep 17 00:00:00 2001 From: Sam Hocevar Date: Thu, 9 Aug 2001 08:20:26 +0000 Subject: [PATCH] =?utf8?q?=20=20*=20Fixed=20a=20bug=20in=20the=20gtk=20int?= =?utf8?q?erface=20which=20caused=20vlc=20to=20go=20amok=20after=20=20=20?= =?utf8?q?=20=20having=20met=20a=20zero-sized=20area.=20=20=20*=20Found=20?= =?utf8?q?out=20how=20to=20type=20'=EF=BF=BD'=20in=20vim=20:-)=20=20=20*?= =?utf8?q?=20Added=20missing=20bloat=20to=20modules=5Fexport.h.=20=20=20*?= =?utf8?q?=20'snapshot*'=20rules=20do=20not=20depend=20on=20'clean',=20and?= =?utf8?q?=20don't=20use=20/tmp=20anymore.=20=20=20*=20Added=20vlc:loop=20?= =?utf8?q?playlist=20command=20to=20go=20back=20at=20the=20beginning.=20?= =?utf8?q?=20=20=20=20Usage:=20vlc=20file1.mpeg=20file2.mpeg=20...=20fileN?= =?utf8?q?.mpeg=20vlc:loop=20=20=20=20=20This=20change=20isn't=20very=20el?= =?utf8?q?egant=20but=20there=20are=20already=20bugs=20in=20the=20=20=20?= =?utf8?q?=20=20playlist=20handling,=20I'll=20try=20to=20polish=20it=20onc?= =?utf8?q?e=20the=20playlist=20is=20fixed.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- AUTHORS | 2 +- ChangeLog | 7 ++- Makefile | 114 ++++++++++++++++++++++-------------------- extras/libdvdcss/ioctl.c | 3 +- include/modules_export.h | 18 +++++++ plugins/dummy/input_dummy.c | 17 +++++-- plugins/gtk/gtk_display.c | 10 ++-- src/input/input.c | 22 ++++---- src/interface/intf_playlist.c | 6 +-- 9 files changed, 121 insertions(+), 78 deletions(-) diff --git a/AUTHORS b/AUTHORS index c56af2bde7..79f44e3a4b 100644 --- a/AUTHORS +++ b/AUTHORS @@ -106,7 +106,7 @@ E: jimmy@via.ecp.fr C: jimmy D: IDCT and YUV transformations -N: H}kan Hjort +N: Håkan Hjort E: d95hjort@dtek.chalmers.se D: Solaris port of the DVD ioctls diff --git a/ChangeLog b/ChangeLog index 2379f5587d..69889f0e7f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,7 +4,12 @@ HEAD - * Solaris DVD decryption support by H}kan Hjort . + * Added vlc:loop playlist command to go back at the beginning. + Usage: vlc file1.mpeg file2.mpeg ... fileN.mpeg vlc:loop + * Fixed a bug in the gtk interface which caused vlc to go amok after + having met a zero-sized area. + * 'snapshot*' rules do not depend on 'clean', and don't use /tmp anymore. + * Solaris DVD decryption support by Håkan Hjort . 0.2.82 Tue, 7 Aug 2001 12:39:16 +0200 diff --git a/Makefile b/Makefile index 676f10523d..68ea837822 100644 --- a/Makefile +++ b/Makefile @@ -90,8 +90,8 @@ endif # # Misc variables # -VLC_QUICKVERSION := $(shell grep 'VLC_VERSION=' configure.in | cut -f2 -d=) -LIBDVDCSS_QUICKVERSION := $(shell grep 'LIBDVDCSS_VERSION=' configure.in | cut -f2 -d=) +VLC_QUICKVERSION := $(shell grep '^ *VLC_VERSION=' configure.in | cut -f2 -d=) +LIBDVDCSS_QUICKVERSION := $(shell grep '^ *LIBDVDCSS_VERSION=' configure.in | cut -f2 -d=) # All symbols must be exported @@ -200,87 +200,94 @@ libdvdcss-uninstall: # # Package generation rules # -snapshot-common: clean - rm -Rf /tmp/vlc - # Copy directory structure in /tmp - find -type d | grep -v CVS | grep -v '\.dep' | while read i ; \ - do mkdir -p /tmp/vlc/$$i ; \ +snapshot-common: + # Check that tmp isn't in the way + @if test -e tmp; then \ + echo "Error: please remove ./tmp, it is in the way"; false; \ + else \ + echo "OK."; mkdir tmp; \ + fi + # Copy directory structure in tmp + find -type d | grep -v '\(\.dep\|snapshot\|CVS\)' | while read i ; \ + do mkdir -p tmp/vlc/$$i ; \ done find debian -mindepth 1 -maxdepth 1 -type d | \ - while read i ; do rm -Rf /tmp/vlc/$$i ; done + while read i ; do rm -Rf tmp/vlc/$$i ; done # Copy .c .h .in .cpp and .glade files find include src plugins -type f -name '*.[chig]*' | while read i ; \ - do cp $$i /tmp/vlc/$$i ; done + do cp $$i tmp/vlc/$$i ; done # Copy plugin Makefiles find plugins -type f -name Makefile | while read i ; \ - do cp $$i /tmp/vlc/$$i ; done + do cp $$i tmp/vlc/$$i ; done # Copy extra programs and documentation - cp -a extras/* /tmp/vlc/extras - cp -a doc/* /tmp/vlc/doc - find /tmp/vlc/extras /tmp/vlc/doc \ - -type d -name CVS -o -type f -name '.*' | while read i ; \ - do rm -Rf $$i ; done + cp -a extras/* tmp/vlc/extras + cp -a doc/* tmp/vlc/doc + find tmp/vlc/extras tmp/vlc/doc \ + -type d -name CVS -o -name '.*' -o -name '*.[o]' | \ + while read i ; do rm -Rf $$i ; done # Copy misc files cp vlc.spec AUTHORS COPYING TODO todo.pl ChangeLog README* INSTALL* \ Makefile Makefile.opts.in Makefile.dep Makefile.modules \ configure configure.in install-sh config.sub config.guess \ - /tmp/vlc/ + tmp/vlc/ # Copy Debian control files for file in debian/*dirs debian/*docs debian/*menu debian/*desktop \ - debian/*copyright ; do cp $$file /tmp/vlc/debian ; done + debian/*copyright ; do cp $$file tmp/vlc/debian ; done for file in control changelog rules ; do \ - cp debian/$$file /tmp/vlc/debian/ ; done + cp debian/$$file tmp/vlc/debian/ ; done # Copy fonts and icons for file in share/*png share/*xpm share/*psf ; do \ - cp $$file /tmp/vlc/share ; done + cp $$file tmp/vlc/share ; done for file in vlc_beos.rsrc vlc.icns gvlc_win32.ico vlc_win32_rc.rc ; do \ - cp share/$$file /tmp/vlc/share/ ; done + cp share/$$file tmp/vlc/share/ ; done snapshot: snapshot-common - # Build archives and clean up + # Build archives F=vlc-${VLC_QUICKVERSION}; \ - rm -Rf /tmp/$$F ; mv /tmp/vlc /tmp/$$F; \ - (cd /tmp ; tar cf $$F.tar $$F ; bzip2 -f -9 < $$F.tar > $$F.tar.bz2; \ - gzip -f -9 $$F.tar ); mv /tmp/$$F.tar.gz /tmp/$$F.tar.bz2 ..; \ - rm -Rf /tmp/$$F + mv tmp/vlc tmp/$$F; (cd tmp ; tar cf $$F.tar $$F); \ + bzip2 -f -9 < tmp/$$F.tar > $$F.tar.bz2; \ + gzip -f -9 tmp/$$F.tar ; mv tmp/$$F.tar.gz . + # Clean up + rm -Rf tmp snapshot-nocss: snapshot-common # Remove libdvdcss - rm -Rf /tmp/vlc/extras/libdvdcss - rm -f /tmp/vlc/*.libdvdcss + rm -Rf tmp/vlc/extras/libdvdcss + rm -f tmp/vlc/*.libdvdcss # Fix debian information - rm -f /tmp/vlc/debian/libdvdcss* - rm -f /tmp/vlc/debian/control + rm -f tmp/vlc/debian/libdvdcss* + rm -f tmp/vlc/debian/control sed -e 's#^ DVDs# unencrypted DVDs#' < debian/control \ | awk '{if(gsub("Package: libdvdcss",$$0))a=1;if(a==0)print $$0;if(a==1&&$$0=="")a=0}' \ - > /tmp/vlc/debian/control - rm -f /tmp/vlc/debian/rules + > tmp/vlc/debian/control + rm -f tmp/vlc/debian/rules sed -e 's#^\(export LIBDVDCSS_FLAGS=\).*#\1"--without-dvdcss"#' < debian/rules \ | awk '{if($$0=="# libdvdcss start")a=1;if(a==0)print $$0;if($$0=="# libdvdcss stop")a=0}' \ - > /tmp/vlc/debian/rules - chmod +x /tmp/vlc/debian/rules - # Build css-disabled archives and clean up + > tmp/vlc/debian/rules + chmod +x tmp/vlc/debian/rules + # Build css-disabled archives F=vlc-${VLC_QUICKVERSION}; G=vlc-${VLC_QUICKVERSION}-nocss; \ - rm -Rf /tmp/$$F ; mv /tmp/vlc /tmp/$$F; \ - (cd /tmp ; tar cf $$G.tar $$F ; bzip2 -f -9 < $$G.tar > $$G.tar.bz2; \ - gzip -f -9 $$G.tar ); mv /tmp/$$G.tar.gz /tmp/$$G.tar.bz2 ..; \ - rm -Rf /tmp/$$F + mv tmp/vlc tmp/$$F; (cd tmp ; tar cf $$G.tar $$F); \ + bzip2 -f -9 < tmp/$$G.tar > $$G.tar.bz2; \ + gzip -f -9 tmp/$$G.tar ; mv tmp/$$G.tar.gz . + # Clean up + rm -Rf tmp libdvdcss-snapshot: snapshot-common # Remove vlc sources and icons, doc, debian directory... - rm -Rf /tmp/vlc/src /tmp/vlc/share /tmp/vlc/plugins /tmp/vlc/doc - rm -Rf /tmp/vlc/extras/GNUgetopt /tmp/vlc/extras/MacOSX_app - rm -Rf /tmp/vlc/debian + rm -Rf tmp/vlc/src tmp/vlc/share tmp/vlc/plugins tmp/vlc/doc + rm -Rf tmp/vlc/extras/GNUgetopt tmp/vlc/extras/MacOSX_app + rm -Rf tmp/vlc/debian # Remove useless headers - rm -f /tmp/vlc/include/* + rm -f tmp/vlc/include/* for file in defs.h.in config.h.in common.h int_types.h ; \ - do cp include/$$file /tmp/vlc/include/ ; done + do cp include/$$file tmp/vlc/include/ ; done # Remove misc files (??? - maybe not really needed) - rm -f /tmp/vlc/vlc.spec /tmp/vlc/INSTALL-win32.txt - mv /tmp/vlc/INSTALL.libdvdcss /tmp/vlc/INSTALL - mv /tmp/vlc/README.libdvdcss /tmp/vlc/README + rm -f tmp/vlc/vlc.spec tmp/vlc/INSTALL-win32.txt + mv tmp/vlc/INSTALL.libdvdcss tmp/vlc/INSTALL + mv tmp/vlc/README.libdvdcss tmp/vlc/README # Fix Makefile - rm -f /tmp/vlc/Makefile + rm -f tmp/vlc/Makefile sed -e 's#^install:#install-unused:#' \ -e 's#^uninstall:#uninstall-unused:#' \ -e 's#^clean:#clean-unused:#' \ @@ -288,13 +295,14 @@ libdvdcss-snapshot: snapshot-common -e 's#^libdvdcss-install:#install:#' \ -e 's#^libdvdcss-uninstall:#uninstall:#' \ -e 's#^libdvdcss-clean:#clean:#' \ - < Makefile > /tmp/vlc/Makefile - # Build archives and clean up + < Makefile > tmp/vlc/Makefile + # Build archives F=libdvdcss-${LIBDVDCSS_QUICKVERSION}; \ - rm -Rf /tmp/$$F ; mv /tmp/vlc /tmp/$$F; \ - (cd /tmp ; tar cf $$F.tar $$F ; bzip2 -f -9 < $$F.tar > $$F.tar.bz2; \ - gzip -f -9 $$F.tar ); mv /tmp/$$F.tar.gz /tmp/$$F.tar.bz2 ..; \ - rm -Rf /tmp/$$F + mv tmp/vlc tmp/$$F; (cd tmp ; tar cf $$F.tar $$F); \ + bzip2 -f -9 < tmp/$$F.tar > $$F.tar.bz2; \ + gzip -f -9 tmp/$$F.tar ; mv tmp/$$F.tar.gz . + # Clean up + rm -Rf tmp deb: dpkg-buildpackage -rfakeroot -us -uc diff --git a/extras/libdvdcss/ioctl.c b/extras/libdvdcss/ioctl.c index ca98cf0f33..dede5fcf07 100644 --- a/extras/libdvdcss/ioctl.c +++ b/extras/libdvdcss/ioctl.c @@ -2,11 +2,12 @@ * ioctl.c: DVD ioctl replacement function ***************************************************************************** * Copyright (C) 1999-2001 VideoLAN - * $Id: ioctl.c,v 1.8 2001/08/08 02:48:44 sam Exp $ + * $Id: ioctl.c,v 1.9 2001/08/09 08:20:26 sam Exp $ * * Authors: Markus Kuespert * Samuel Hocevar * Jon Lech Johansen + * Håkan Hjort * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/include/modules_export.h b/include/modules_export.h index 293d700627..a695099b8a 100644 --- a/include/modules_export.h +++ b/include/modules_export.h @@ -89,6 +89,11 @@ typedef struct module_symbols_s void ( * input_DelArea ) ( struct input_thread_s *, struct input_area_s * ); + void ( * InitBitstream ) ( struct bit_stream_s *, + struct decoder_fifo_s *, + void ( * ) ( struct bit_stream_s *, + boolean_t ), + void * ); int ( * input_InitStream ) ( struct input_thread_s *, size_t ); void ( * input_EndStream ) ( struct input_thread_s * ); @@ -98,6 +103,8 @@ typedef struct module_symbols_s struct data_packet_s *, struct es_descriptor_s *, boolean_t, boolean_t ); + void ( * input_DecodePES ) ( struct decoder_fifo_s *, + struct pes_packet_s * ); struct es_descriptor_s * ( * input_ParsePS ) ( struct input_thread_s *, struct data_packet_s * ); void ( * input_DemuxPS ) ( struct input_thread_s *, @@ -109,6 +116,10 @@ typedef struct module_symbols_s struct es_descriptor_s *, boolean_t, boolean_t ); + int ( * input_ClockManageControl ) ( struct input_thread_s *, + struct pgrm_descriptor_s *, + mtime_t ); + int ( * input_NetlistInit ) ( struct input_thread_s *, int, int, size_t, int ); struct iovec * ( * input_NetlistGetiovec ) ( void * p_method_data ); @@ -166,14 +177,17 @@ typedef struct module_symbols_s (p_symbols)->input_DelProgram = input_DelProgram; \ (p_symbols)->input_AddArea = input_AddArea; \ (p_symbols)->input_DelArea = input_DelArea; \ + (p_symbols)->InitBitstream = InitBitstream; \ (p_symbols)->input_InitStream = input_InitStream; \ (p_symbols)->input_EndStream = input_EndStream; \ (p_symbols)->input_ParsePES = input_ParsePES; \ (p_symbols)->input_GatherPES = input_GatherPES; \ + (p_symbols)->input_DecodePES = input_DecodePES; \ (p_symbols)->input_ParsePS = input_ParsePS; \ (p_symbols)->input_DemuxPS = input_DemuxPS; \ (p_symbols)->input_DemuxTS = input_DemuxTS; \ (p_symbols)->input_DemuxPSI = input_DemuxPSI; \ + (p_symbols)->input_ClockManageControl = input_ClockManageControl; \ (p_symbols)->input_NetlistInit = input_NetlistInit; \ (p_symbols)->input_NetlistGetiovec = input_NetlistGetiovec; \ (p_symbols)->input_NetlistMviovec = input_NetlistMviovec; \ @@ -252,16 +266,20 @@ extern module_symbols_t* p_symbols; # define input_AddArea p_symbols->input_AddArea # define input_DelArea p_symbols->input_DelArea +# define InitBitstream p_symbols->InitBitstream # define input_InitStream p_symbols->input_InitStream # define input_EndStream p_symbols->input_EndStream # define input_ParsePES p_symbols->input_ParsePES # define input_GatherPES p_symbols->input_GatherPES +# define input_DecodePES p_symbols->input_DecodePES # define input_ParsePS p_symbols->input_ParsePS # define input_DemuxPS p_symbols->input_DemuxPS # define input_DemuxTS p_symbols->input_DemuxTS # define input_DemuxPSI p_symbols->input_DemuxPSI +# define input_ClockManageControl p_symbols->input_ClockManageControl + # define input_NetlistInit p_symbols->input_NetlistInit # define input_NetlistGetiovec p_symbols->input_NetlistGetiovec # define input_NetlistMviovec p_symbols->input_NetlistMviovec diff --git a/plugins/dummy/input_dummy.c b/plugins/dummy/input_dummy.c index b4144038de..eeaa6dc3ff 100644 --- a/plugins/dummy/input_dummy.c +++ b/plugins/dummy/input_dummy.c @@ -2,7 +2,7 @@ * input_dummy.c: dummy input plugin, to manage "vlc:***" special options ***************************************************************************** * Copyright (C) 2001 VideoLAN - * $Id: input_dummy.c,v 1.4 2001/07/26 03:13:30 sam Exp $ + * $Id: input_dummy.c,v 1.5 2001/08/09 08:20:26 sam Exp $ * * Authors: Samuel Hocevar * @@ -45,6 +45,7 @@ #include "interface.h" #include "intf_msg.h" +#include "intf_playlist.h" #include "main.h" @@ -139,23 +140,31 @@ static void DummyOpen( input_thread_t * p_input ) /* Check for a "vlc:quit" command */ if( i_len == 4 && !strncasecmp( psz_name, "quit", 4 ) ) { - intf_WarnMsg( 1, "input: playlist command `quit'" ); + intf_WarnMsg( 2, "input: command `quit'" ); p_main->p_intf->b_die = 1; return; } + /* Check for a "vlc:loop" command */ + if( i_len == 4 && !strncasecmp( psz_name, "loop", 4 ) ) + { + intf_WarnMsg( 2, "input: command `loop'" ); + intf_PlaylistJumpto( p_main->p_playlist, -1 ); + return; + } + /* Check for a "vlc:pause:***" command */ if( i_len > 6 && !strncasecmp( psz_name, "pause:", 6 ) ) { i_arg = atoi( psz_name + 6 ); - intf_WarnMsgImm( 1, "input: playlist command `pause %i'", i_arg ); + intf_WarnMsgImm( 2, "input: command `pause %i'", i_arg ); msleep( i_arg * 1000000 ); return; } - intf_ErrMsg( "input error: unknown playlist command `%s'", psz_name ); + intf_ErrMsg( "input error: unknown command `%s'", psz_name ); } diff --git a/plugins/gtk/gtk_display.c b/plugins/gtk/gtk_display.c index 53b930d205..cc2da595bc 100644 --- a/plugins/gtk/gtk_display.c +++ b/plugins/gtk/gtk_display.c @@ -2,7 +2,7 @@ * gtk_display.c: Gtk+ tools for main interface ***************************************************************************** * Copyright (C) 1999, 2000 VideoLAN - * $Id: gtk_display.c,v 1.5 2001/07/25 03:12:33 sam Exp $ + * $Id: gtk_display.c,v 1.6 2001/08/09 08:20:26 sam Exp $ * * Authors: Samuel Hocevar * Stéphane Borel @@ -179,9 +179,12 @@ gint GtkModeManage( intf_thread_t * p_intf ) break; } - /* slider for seekable streams */ + /* initialize and show slider for seekable streams */ if( p_intf->p_input->stream.b_seekable ) { + p_intf->p_sys->p_adj->value = p_intf->p_sys->f_adj_oldvalue = 0; + gtk_signal_emit_by_name( GTK_OBJECT( p_intf->p_sys->p_adj ), + "value_changed" ); gtk_widget_show( GTK_WIDGET( p_slider ) ); } @@ -197,8 +200,7 @@ gint GtkModeManage( intf_thread_t * p_intf ) p_intf->p_sys->i_part = 0; p_intf->p_input->stream.b_changed = 0; - intf_WarnMsg( 3, - "intf info: menus refreshed as stream has changed" ); + intf_WarnMsg( 3, "intf: stream has changed, refreshing interface" ); } else { diff --git a/src/input/input.c b/src/input/input.c index 3bdee5cb1d..51ba34b323 100644 --- a/src/input/input.c +++ b/src/input/input.c @@ -4,7 +4,7 @@ * decoders. ***************************************************************************** * Copyright (C) 1998, 1999, 2000 VideoLAN - * $Id: input.c,v 1.128 2001/08/05 15:32:46 gbazin Exp $ + * $Id: input.c,v 1.129 2001/08/09 08:20:26 sam Exp $ * * Authors: Christophe Massiot * @@ -168,6 +168,8 @@ input_thread_t *input_CreateThread ( playlist_item_t *p_item, int *pi_status ) p_input->pf_network_close = NetworkClose; #endif + intf_WarnMsg( 1, "input: playlist item `%s'", p_input->p_source ); + /* Create thread. */ if( vlc_thread_create( &p_input->thread_id, "input", (void *) RunThread, (void *) p_input ) ) @@ -238,13 +240,11 @@ static void RunThread( input_thread_t *p_input ) if( InitThread( p_input ) ) { - /* If we failed, wait before we are killed, and exit */ *p_input->pi_status = THREAD_ERROR; p_input->b_error = 1; ErrorThread( p_input ); DestroyThread( p_input ); - free( p_input ); return; } @@ -492,8 +492,8 @@ static void EndThread( input_thread_t * p_input ) struct tms cpu_usage; times( &cpu_usage ); - intf_Msg("input stats: cpu usage (user: %d, system: %d)", - cpu_usage.tms_utime, cpu_usage.tms_stime); + intf_Msg( "input stats: cpu usage (user: %d, system: %d)", + cpu_usage.tms_utime, cpu_usage.tms_stime ); } #endif @@ -604,7 +604,7 @@ static void FileOpen( input_thread_t * p_input ) p_input->stream.p_selected_area->i_tell = 0; vlc_mutex_unlock( &p_input->stream.stream_lock ); - intf_WarnMsg( 1, "input: opening file `%s'", p_input->p_source ); + intf_WarnMsg( 2, "input: opening file `%s'", p_input->p_source ); if( (p_input->i_handle = open( psz_name, /*O_NONBLOCK | O_LARGEFILE*/0 )) == (-1) ) { @@ -620,7 +620,7 @@ static void FileOpen( input_thread_t * p_input ) *****************************************************************************/ static void FileClose( input_thread_t * p_input ) { - intf_WarnMsg( 1, "input: closing file `%s'", p_input->p_source ); + intf_WarnMsg( 2, "input: closing file `%s'", p_input->p_source ); close( p_input->i_handle ); @@ -750,7 +750,7 @@ static void NetworkOpen( input_thread_t * p_input ) } } - intf_WarnMsg( 2, "input: server: %s port: %d broadcast: %s", + intf_WarnMsg( 2, "input: server=%s port=%d broadcast=%s", psz_server, i_port, psz_broadcast ); /* Open a SOCK_DGRAM (UDP) socket, in the AF_INET domain, automatic (0) @@ -758,7 +758,7 @@ static void NetworkOpen( input_thread_t * p_input ) p_input->i_handle = socket( AF_INET, SOCK_DGRAM, 0 ); if( p_input->i_handle == -1 ) { - intf_ErrMsg("input error: can't create socket : %s", strerror(errno)); + intf_ErrMsg( "input error: can't create socket (%s)", strerror(errno) ); p_input->b_error = 1; return; } @@ -808,7 +808,7 @@ static void NetworkOpen( input_thread_t * p_input ) if( bind( p_input->i_handle, (struct sockaddr *)&sock, sizeof( sock ) ) < 0 ) { - intf_ErrMsg("input error: can't bind socket (%s)", strerror(errno)); + intf_ErrMsg( "input error: can't bind socket (%s)", strerror(errno) ); close( p_input->i_handle ); p_input->b_error = 1; return; @@ -827,7 +827,7 @@ static void NetworkOpen( input_thread_t * p_input ) if( connect( p_input->i_handle, (struct sockaddr *) &sock, sizeof( sock ) ) == (-1) ) { - intf_ErrMsg( "input error: can't connect socket, %s", + intf_ErrMsg( "input error: can't connect socket (%s)", strerror(errno) ); close( p_input->i_handle ); p_input->b_error = 1; diff --git a/src/interface/intf_playlist.c b/src/interface/intf_playlist.c index 52ecdbf3cb..b6bafa3fc4 100644 --- a/src/interface/intf_playlist.c +++ b/src/interface/intf_playlist.c @@ -2,7 +2,7 @@ * intf_playlist.c : Playlist management functions ***************************************************************************** * Copyright (C) 1999, 2000 VideoLAN - * $Id: intf_playlist.c,v 1.7 2001/05/30 17:03:12 sam Exp $ + * $Id: intf_playlist.c,v 1.8 2001/08/09 08:20:26 sam Exp $ * * Authors: Samuel Hocevar * @@ -164,11 +164,11 @@ void intf_PlaylistNext( playlist_t * p_playlist ) void intf_PlaylistPrev( playlist_t * p_playlist ) { vlc_mutex_lock( &p_playlist->change_lock ); - p_playlist->i_mode = -p_playlist->i_mode; + p_playlist->i_mode = -p_playlist->i_mode; NextItem( p_playlist ); - p_playlist->i_mode = -p_playlist->i_mode; + vlc_mutex_unlock( &p_playlist->change_lock ); } -- 2.11.4.GIT