Don't crash if removing a nonexistent value.

1999-10-31  Tor Lillqvist  <tml@iki.fi>

* gcache.c (g_cache_remove): Don't crash if removing a nonexistent
value.

* gutils.c (gwin_getlocale): New Win32-specific function, returns
a Unixish current locale string (en, zh_TW etc).

* glib.h: Declare it.

* glib.def: Export it.

* testglib.c: Test it.

* gmessages.c (Win32: ensure_stdout_valid): Some improvements,
make sure we don't call AllocConsole several times, which I think
has happened.
This commit is contained in:
Tor Lillqvist
1999-10-31 12:15:34 +00:00
committed by Tor Lillqvist
parent a2760140c8
commit 30cc3ed1fe
22 changed files with 1357 additions and 18 deletions

View File

@@ -914,8 +914,13 @@ main (int argc,
#ifdef G_HAVE_GINT64
g_assert (GUINT64_SWAP_LE_BE (gu64t1) == gu64t2);
#endif
g_print ("ok\n");
#ifdef G_OS_WIN32
g_print ("current locale: %s\n", gwin_getlocale ());
#endif
return 0;
}