• Allison Lortie's avatar
    Add support for compacting DBusStrings to release wasted memory. · 8c6b0ab3
    Allison Lortie authored
    2007-09-19  Ryan Lortie  <desrt@desrt.ca>
    
            * dbus/dbus-string.[ch] (compact, _dbus_string_compact,
            _dbus_string_lock): new compact function to free up allocated memory
            that is no longer used.
    
            * dbus/dbus-message.c (load_message): call _dbus_string_compact on the
            message loader buffer.
    
            * dbus/dbus-transport-socket.c (do_reading, do_writing): call
            _dbus_string_compact on the incoming/outgoing "encoded" buffers.
    
            * dbus/dbus-string-util.c (_dbus_string_test): add a few tests for
            string compacting.
    8c6b0ab3
dbus-string.c 73.4 KB