1
mirror of https://code.videolan.org/videolan/vlc synced 2024-08-27 04:21:53 +02:00

input: check malloc return

This commit is contained in:
Jean-Baptiste Kempf 2015-04-28 15:09:57 +02:00
parent 8a8b2b73f3
commit 46437d4aa3

View File

@ -53,6 +53,8 @@ struct seekpoint_t
static inline seekpoint_t *vlc_seekpoint_New( void )
{
seekpoint_t *point = (seekpoint_t*)malloc( sizeof( seekpoint_t ) );
if( !point )
return NULL;
point->i_byte_offset =
point->i_time_offset = -1;
point->psz_name = NULL;
@ -96,6 +98,8 @@ typedef struct input_title_t
static inline input_title_t *vlc_input_title_New(void)
{
input_title_t *t = (input_title_t*)malloc( sizeof( input_title_t ) );
if( !t )
return NULL;
t->psz_name = NULL;
t->b_menu = false;