Segfault fix for hal 0.5.2
David Zeuthen
david at fubar.dk
Tue May 24 10:42:16 PDT 2005
On Tue, 2005-05-24 at 10:08 +0200, Martin Pitt wrote:
> Hi David!
>
> We have a report about hald segfaulting for some devices:
>
> https://bugzilla.ubuntu.com/show_bug.cgi?id=11060
>
> In that case, serial_add() manages to read out a property value for
> info.product which is NULL; hal_property_new_string() calls
> g_utf8_validate() on NULL which goes BOOM.
>
> I fixed that at a very low level in hal_property_new_string() so that
> similar issues get caught as well. I just assign an empty string to
> the property if the value argument is NULL.
That's pretty sensible, perhaps we should even print a warning when we
encounter NULL as well? I'm not sure.. Anyway, I committed the patch you
sent.
Thanks,
David
_______________________________________________
hal mailing list
hal at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/hal
More information about the Hal
mailing list