# include "config.h"
#endif
-#include <vlc/vlc.h>
+#include <vlc_common.h>
#include <vlc_plugin.h>
#include <vlc_vout.h>
#include <vlc_interface.h>
"creating one file per image. In this case, " \
"the number is not appended to the filename." )
-static const char *psz_format_list[] = { "png", "jpeg" };
-static const char *psz_format_list_text[] = { "PNG", "JPEG" };
+static const char *const psz_format_list[] = { "png", "jpeg" };
+static const char *const psz_format_list_text[] = { "PNG", "JPEG" };
#define CFG_PREFIX "image-out-"
set_callbacks( Create, Destroy );
vlc_module_end();
-static const char *ppsz_vout_options[] = {
+static const char *const ppsz_vout_options[] = {
"format", "width", "height", "ratio", "prefix", "replace", NULL
};
{
msg_Err( p_this, "unable to create image handler") ;
FREENULL( p_vout->p_sys->psz_prefix );
+ FREENULL( p_vout->p_sys->psz_format );
FREENULL( p_vout->p_sys );
return VLC_EGENERIC;
}
psz_prefix = psz_tmp;
psz_filename = (char *)malloc( 10 + strlen( psz_prefix )
+ strlen( p_vout->p_sys->psz_format ) );
+ if( !psz_filename )
+ return;
+
if( p_vout->p_sys->b_replace )
{
sprintf( psz_filename, "%s.%s", psz_prefix,