Bug 523877 – gbookmarkfile: avoid using g_string_append_printf() and
authorClaudio Saavedra <csaavedra@gnome.org>
Sat, 22 Mar 2008 23:52:39 +0000 (23:52 +0000)
committerClaudio Saavedra <csaavedra@src.gnome.org>
Sat, 22 Mar 2008 23:52:39 +0000 (23:52 +0000)
commit05b1004080a458b13390571ea2834b4a33a436a5
tree174b3757f7187c40ab8e29af3c4d5447e346e96f
parentc14b3842f211ab9ec8ecb6b4fe058c6d12934350
Bug 523877 – gbookmarkfile: avoid using g_string_append_printf() and

2008-03-22  Claudio Saavedra  <csaavedra@gnome.org>

Bug 523877 – gbookmarkfile: avoid using g_string_append_printf() and
other optimizations

* glib/gbookmarkfile.c: (bookmark_metadata_dump),
(bookmark_item_dump), (g_bookmark_file_dump), (expand_exec_line):
Replace all calls to g_string_append_printf with g_strconcat () or
g_string_append () where appropriate, to reduce the file creation time.
Also, use g_string_sized_new () with an appropriate buffer size instead
of g_string_new (NULL), to reduce time spent in memory reallocation.
(#523877, Claudio Saavedra, Emmanuele Bassi)

svn path=/trunk/; revision=6752
ChangeLog
glib/gbookmarkfile.c