I don't immediately see a solution for.
}
*buf++ = '\0';
- buf = *ppsz_string = realloc (*ppsz_string, buf - *ppsz_string);
+ buf = realloc (*ppsz_string, buf - *ppsz_string);
+ if( buf )
+ *ppsz_string = buf;
}
return VLC_SUCCESS;
}
if( i_read < p_sys->i_data_len - i_pos ) break; /* Done */
+ /* XXX this looks fishy and inefficient */
i_pos += i_read;
p_sys->i_data_len += 1024;
p_sys->psz_data = realloc( p_sys->psz_data, p_sys->i_data_len * sizeof( char * ) +1 );