Commit d6a720cb authored by Steve Lhomme's avatar Steve Lhomme

misc possible buffer/resource misuse & tidy compilation

parent 95024e06
......@@ -33,7 +33,7 @@
#include <vlc/decoder.h>
/* ffmpeg header */
#define HAVE_MMX
#define HAVE_MMX 1
#ifdef HAVE_FFMPEG_AVCODEC_H
# include <ffmpeg/avcodec.h>
#else
......
......@@ -29,7 +29,7 @@
#include <vlc/decoder.h>
/* ffmpeg header */
#define HAVE_MMX
#define HAVE_MMX 1
#ifdef HAVE_FFMPEG_AVCODEC_H
# include <ffmpeg/avcodec.h>
#else
......@@ -360,8 +360,8 @@ static void LibavcodecCallback( void *p_opaque, int i_level,
psz_item_name = p_avc->item_name(p_opaque);
psz_new_format = malloc( strlen(psz_format) + strlen(psz_item_name)
+ 18 + 5 );
sprintf( psz_new_format, "%s (%s@%p)", psz_format,
p_avc->item_name(p_opaque), p_opaque );
snprintf( psz_new_format, strlen(psz_format) + strlen(psz_item_name)
+ 18 + 5, "%s (%s@%p)", psz_format, p_avc->item_name(p_opaque), p_opaque );
msg_GenericVa( p_this, i_vlc_level, MODULE_STRING, psz_new_format, va );
free( psz_new_format );
}
......
......@@ -483,6 +483,9 @@ int __vlc_cond_destroy( char * psz_file, int i_line, vlc_cond_t *p_condvar )
i_result = !CloseHandle( p_condvar->event )
|| !CloseHandle( p_condvar->semaphore );
if( p_condvar->semaphore != NULL )
DeleteCriticalSection( &p_condvar->csection );
#elif defined( HAVE_KERNEL_SCHEDULER_H )
p_condvar->init = 0;
return 0;
......
......@@ -301,6 +301,7 @@ playlist_item_t * playlist_NodeCreate( playlist_t *p_playlist, int i_view,
p_item->pp_parents = NULL;
p_item->i_parents = 0;
p_item->i_serial = 0;
p_item->i_flags |= PLAYLIST_SKIP_FLAG; /* Default behaviour */
......
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