[Flac-dev] bug in xmms plugin v 1.1.2

Josh Coalson xflac at yahoo.com
Thu Sep 1 22:05:10 PDT 2005


OK, I think I've fixed all the pointer problems with the
"new" http streaming code in CVS.

Josh


--- Dan Mick <dan.mick at sun.com> wrote:

> I, like others here, have noticed that the xmms plugin is broken for 
> first use in version 1.1.2.  The problem is confusion between 
> dynamically-allocated and statically-allocated strings.  A quick, 
> although perhaps not elegant, fix is included below.
> 
> Note: you would not see this if you already had a [flac] section in
> your 
> config file, which probably explains how it escaped the notice of 
> whoever added the streaming support, which is where this was
> introduced.
> (BTW, thank you for the streaming support.)
> 
> ------- plugin.c -------
> --- /tmp/sccs.zza4YF    Thu Mar 31 20:03:46 2005
> +++ plugin.c    Mon Mar 28 19:58:20 2005
> @@ -219,6 +219,12 @@
> 
>          is_big_endian_host_ = (*((FLAC__byte*)(&test)))? false :
> true;
> 
> +       /* make all the config struct strings dynamic, to ease our
> life */
> +       flac_cfg.stream.proxy_host =
> g_strdup(flac_cfg.stream.proxy_host);
> +       flac_cfg.stream.proxy_user =
> g_strdup(flac_cfg.stream.proxy_user);
> +       flac_cfg.stream.proxy_pass =
> g_strdup(flac_cfg.stream.proxy_pass);
> +       flac_cfg.stream.save_http_path = 
> g_strdup(flac_cfg.stream.save_http_path);
> +
>          flac_cfg.title.tag_override = FALSE;
>          g_free(flac_cfg.title.tag_format);
>          flac_cfg.title.convert_char_set = FALSE;
> _______________________________________________
> Flac-dev mailing list
> Flac-dev at xiph.org
> http://lists.xiph.org/mailman/listinfo/flac-dev
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


More information about the Flac-dev mailing list