dbus linked with libglib by default
ross at burtonini.com
Thu Sep 21 07:25:34 PDT 2006
On Thu, 2006-09-21 at 17:15 +0300, Kimmo Hämäläinen wrote:
> On Thu, 2006-09-21 at 16:23, ext frederic heem wrote:
> > Apart from the initial work to change all dbus function to their glib
> > counterpart, there isn't any drawback at all.
> There is a drawback: out-of-memory (OOM) handling. The Glib library is
> inconvenient in an embedded environment when the RAM really runs out
> (and there is no swap to save you). As someone said, Glib typically
> calls abort() in OOM. And if D-Bus is used in a system-critical daemon,
> you don't want the daemon to call abort() -- you want to keep the daemon
> So, using Glib in D-Bus is not a good idea until Glib allows the
> programmer to handle OOM.
"Typically" is the wrong word: all of the default allocators in GLib
abort on OOM. g_alloc() and friends return a valid pointer, or don't
return. This is *not* what DBus wants.
Ross Burton mail: ross at burtonini.com
jabber: ross at burtonini.com
PGP Fingerprint: 1A21 F5B0 D8D0 CFE3 81D4 E25A 2D09 E447 D0B4 33DF
More information about the dbus