minor optimization.

Wed Mar  1 10:39:39 2000  Tim Janik  <timj@gtk.org>

        * gslist.c (g_slist_reverse): minor optimization.

        * testglib.c (g_node_test): added a couple of tests for
        g_node_copy().

        * glib.h:
        * gnode.c (g_node_copy): new function to copy subtrees,
        supplied by dbsears@ix.netcom.com.
        changed iterator to walk the children list backwards, so
        we get down from O(n^2) to O(n).

        * gnode.c (g_node_first_sibling): applied patch from
        dbsears@ix.netcom.com to optimize access if node->parent
        is present.

        * gutils.c (g_get_any_init): backed out HAVE_PW_GECOS check around
        assignment of g_real_name, sicne HAVE_PW_GECOS is never defined and
        thus breaks the original code.

        * merged changes from 1.2.7.

Sat Feb 19 19:43:29 2000  Tim Janik  <timj@gtk.org>

        * testgmodule.c (main): added test to check that not yet bound symbols
        in shared libraries of the main module are retrievable, from David Gero.

Fri Jan 28 11:37:41 2000  Owen Taylor  <otaylor@redhat.com>

        Bug #4156 - Changes vaguely modelled after Scott Gifford's patch

        * gtimer.c (g_timer_elapsed): Never report negative times -
        clip times to 0.

        * gmain.c (g_timeout_prepare): Guard against unexpected
        clock shifts by never setting a timeout of more than
        data->interval msecs.
This commit is contained in:
Tim Janik
2000-03-01 09:44:10 +00:00
committed by Tim Janik
parent d568a76ae4
commit db8baf6978
26 changed files with 528 additions and 162 deletions

View File

@@ -1159,6 +1159,7 @@ void g_node_pop_allocator (void);
GNode* g_node_new (gpointer data);
void g_node_destroy (GNode *root);
void g_node_unlink (GNode *node);
GNode* g_node_copy (GNode *node);
GNode* g_node_insert (GNode *parent,
gint position,
GNode *node);
@@ -1598,24 +1599,22 @@ gchar* g_strjoin (const gchar *separator,
*/
gchar* g_strcompress (const gchar *source);
/* Copy a string escaping nonprintable characters like in C strings.
* Inverse of g_strcompress. The exceptions parameter, if non-NULL, points
* to a string containing characters that are not to be escaped.
*/
gchar* g_strescape (const gchar *source,
const gchar *exceptions);
/*
* Convert between the operating system (or C runtime)
/* Convert between the operating system (or C runtime)
* representation of file names and UTF-8.
*/
gchar* g_filename_to_utf8 (const gchar *opsysstring);
gchar* g_filename_from_utf8 (const gchar *utf8string);
/* Deprecated API:
* gchar* g_strescape (const gchar *source);
* Luckily this function wasn't much used.
* Add a second NULL parameter in calls for mostly identical semantics.
/* Copy a string escaping nonprintable characters like in C strings.
* Inverse of g_strcompress. The exceptions parameter, if non-NULL, points
* to a string containing characters that are not to be escaped.
*
* Deprecated API: gchar* g_strescape (const gchar *source);
* Luckily this function wasn't used much, using NULL as second parameter
* provides mostly identical semantics.
*/
gchar* g_strescape (const gchar *source,
const gchar *exceptions);
gpointer g_memdup (gconstpointer mem,
guint byte_size);