Re: [evolution-patches] Patch for leaks in gtkhtml



Since its getting a const in, you should definitely keep the strdup
there.  e..g this would cause real problems if you ever set a const
string as a value, which isn't entirely inconcievable.

Something calling that mustn't be freeing its value.

(wouldn't this change be spitting a warning about losing the const
qualifier?).

On Thu, 2005-07-07 at 12:02 +0200, Kjartan Maraas wrote:
>  void
>  html_object_set_data (HTMLObject *object, const gchar *key, const
> gchar *value)
>  {
> -       g_datalist_set_data_full (&object->object_data, key, g_strdup
> (value), g_free);
> +       g_datalist_set_data_full (&object->object_data, key, value,
> g_free);
>  } 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]