[packagekit] Pk 0.7 crash

Richard Hughes hughsient at gmail.com
Thu Jul 28 02:11:45 PDT 2011


On 27 July 2011 20:48, Daniel Nicoletti <dantti85-pk at yahoo.com.br> wrote:
> as expected there is a crash with the new dbus stuff :P

Heh, I expected enough :)

> This code crashes when, updated is NULL,
> but this workaround is not so nice imo.
>       g_variant_new ("(ssssssssssss)",
>      updated == NULL ? "" : updated)
> Richard dunno if you knew this problem but now you
> know that I know :P

Yup, that fix is basically what I've done in git, along with a few
more. The basic problem is in DBus, which has not yet committed the
patch needed for 'maybe' support, which would allow us to have empty
strings, rather than the "" hack. The reason it worked before was that
dbus-glib automatically converted a NULL string to "" in a workaround,
and so applications didn't have to do anything special.

See https://bugs.freedesktop.org/show_bug.cgi?id=27857 for the DBus
patch, and until that's committed we'll have to play the ""-type
games.

Richard



More information about the PackageKit mailing list