Commit Graph

1572 Commits

Author SHA1 Message Date
Sebastian Wilhelmi
72ac1282b8 Fixed missing definition for ppc code. Fix by Mark McLoughlin
2004-03-02  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/gatomic.c: Fixed missing definition for ppc code. Fix by
	Mark McLoughlin <mark@skynet.ie>.
2004-03-02 09:47:37 +00:00
Owen Taylor
109ebb109a === Released 2.3.5 ===
Mon Mar  1 16:49:51 2004  Owen Taylor  <otaylor@redhat.com>

        * === Released 2.3.5 ===

        * configure.in: Version 2.3.5, interface ago 0.

        * NEWS: Some further updates.
2004-03-02 00:05:36 +00:00
Owen Taylor
44ef900675 Don't call waitpid() on a source that has already exited.
Mon Mar  1 15:49:09 2004  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c (check_for_child_exited): Don't
        call waitpid() on a source that has already exited.

        * glib/gmain.c (g_child_watch_check): Return TRUE
        only if the child actually exited.
2004-03-01 20:56:47 +00:00
Owen Taylor
38cbfaeb7a Patch from J. Ali Harlow
Mon Mar  1 15:39:57 2004  Owen Taylor  <otaylor@redhat.com>

       Patch from J. Ali Harlow

        * configure.in: Use void * not HANDLE for GPid on win32.

        * glib/gspawn.[ch] glib/gspawn-win32.[ch] glib/glib.def:
        Add g_spawn_close_pid().

        * glib/gspawn.[ch]: Make g_spawn functions take
        GPid * instead if int * (GPid == int on unix, will
        produce compile warnings until fixed on Win32.)

        * tests/child-test.c: Make the test a little more
        inappropriately verbose.

        * glib/gmain.c: Add some documentation warnings about
        not closing @pid while the source is active.
2004-03-01 20:47:49 +00:00
Tim Janik
6c6e41510a - exit with $? instead of 1 in case of failure - exit with $? if
Mon Mar  1 20:32:06 2004  Tim Janik  <timj@gtk.org>

        * autogen.sh:
        - exit with $? instead of 1 in case of failure
        - exit with $? if ./configure failed
          (that's so autogen.sh && make lines work)
        - removed --enable-gtk-doc option
        - added $AUTOGEN_CONFIGURE_ARGS
2004-03-01 19:32:34 +00:00
Owen Taylor
3e8b3a13f5 Clarify doc comment.
Mon Mar  1 09:17:32 2004  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c (g_main_depth): Clarify doc comment.
2004-03-01 14:20:30 +00:00
Sebastian Wilhelmi
2af063c00e Define g_atomic_(int|pointer)_get only for
2004-03-01  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/gatomic.c: Define g_atomic_(int|pointer)_get only for
	G_ATOMIC_OP_MEMORY_BARRIER_NEEDED. Spotted by Hans Breuer.
2004-03-01 10:21:26 +00:00
Owen Taylor
e1c15eb0d1 Fix leftover references to g_main_context_depth() in docs.
Sun Feb 29 21:42:47 2004  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c: Fix leftover references to
        g_main_context_depth() in docs.
2004-03-01 02:45:15 +00:00
Owen Taylor
0875017ad1 Add g_main_depth() (Request from Tim Janik and Stefan Westerfeld)
Sun Feb 29 21:34:34 2004  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.[ch]: Add g_main_depth() (Request from
        Tim Janik and Stefan Westerfeld)
2004-03-01 02:41:09 +00:00
Matthias Clasen
7b3042f8a7 Update for 2.3.4 2004-02-29 23:22:15 +00:00
Hans Breuer
3761f849cc added win32 api based implementation for G_PLATFORM_WIN32, !__GNUC__
2003-02-29  Hans Breuer  <hans@breuer.org>

	* glib/gatomic.c : added win32 api based implementation
	for G_PLATFORM_WIN32, !__GNUC__

	* glb/glib.def : change to g_atomi_* no _fallback
2004-02-29 21:32:27 +00:00
Sebastian Wilhelmi
fe2efd06a0 Moved the assembler functions from gatomic.h to gatomic.c, which makes for
2004-02-29  Sebastian Wilhelmi  <seppi@seppi.de>

	* configure.in, glib/gatomic.c, glib/gatomic.h: Moved the
	assembler functions from gatomic.h to gatomic.c, which makes for
	better maintainability. Also use gint instead of gint32 to be able
	to use reference counting for ABI-fixed structures with
	gint/guint.

	* glib/gthread.h: Adapted accordingly.

	* tests/atomic-test.c: Updated to test for G_MAXINT and G_MININT.

	* glib/glib-overrides.txt, glib/glib-sections.txt,
	glib/tmpl/atomic_operations.sgml: Updated according to code changes.
2004-02-29 16:47:48 +00:00
Hans Breuer
4d470362b2 updated externals, including those from bug #135386
2003-02-28  Hans Breuer  <hans@breuer.org>

	* glib/glib.def : updated externals, including those
	from bug #135386

	* glib/makefile.msc.in : build gatomic.c

	* glibconfig.h.win32.in : removed duplicate definition
	of G_MAXSIZE, typedef void* GPid instead of int

	* tests/child-test.c  glib/gmain.c :
	applied patch from J. Ali Harlow <ali@juiblex.co.uk> to fix
	g_child_watch implementation on win32, bug #50296
2004-02-28 13:03:55 +00:00
Matthias Clasen
3ce97fa284 Documentation updates. 2004-02-27 21:11:51 +00:00
Sebastian Wilhelmi
d77011caf4 Reading access to ref_count only with g_atomic_int_get().
2004-02-27  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/gasyncqueue.c, glib/gasyncqueue.h: Reading access to
	ref_count only with g_atomic_int_get().
2004-02-27 17:19:32 +00:00
Sebastian Wilhelmi
4054cc5979 Use g_atomic_int_(inc|dec_and_test) for reference counting.
2004-02-27  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/gasyncqueue.c, glib/gasyncqueue.h: Use
	g_atomic_int_(inc|dec_and_test) for reference
	counting. g_async_queue_unref_and_unlock and
	g_async_queue_ref_locked is deprecated, but still there to
	preserve ABI.
2004-02-27 16:06:31 +00:00
Matthias Clasen
9e26679c3d quote AC_DEFUN macro names so automake 1.8 won't whine at us. (#134882)
Fri Feb 27 02:00:34 2004  Matthias Clasen  <maclas@gmx.de>

	* acglib.m4: quote AC_DEFUN macro names so automake
	1.8 won't whine at us.  (#134882)
2004-02-27 00:57:25 +00:00
Matthias Clasen
6b42452b3b Translate from locale era to AD in g_date_set_parse(). (#133400, Theppitak
Fri Feb 27 01:44:41 2004  Matthias Clasen <maclas@gmx.de>

	* glib/gdate.c: Translate from locale era to AD in
	g_date_set_parse().  (#133400, Theppitak Karoonboonyanan)
2004-02-27 00:42:39 +00:00
Matthias Clasen
78adb5c69a Don't modify errno. (#116617, Balazs Scheidler)
Fri Feb 27 00:46:29 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gstrfuncs.c (g_strerror): Don't modify errno.  (#116617,
	Balazs Scheidler)
2004-02-26 23:43:45 +00:00
Sebastian Wilhelmi
960a9899a7 Last commit log was wrong: Should have been:
2004-02-26  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/gatomic.h: Fix the !G_THREADS_ENABLED case.
2004-02-26 17:33:09 +00:00
Sebastian Wilhelmi
c36865b1ec Only run, if threads are enabled.
2004-02-26  Sebastian Wilhelmi  <seppi@seppi.de>

	* tests/child-test.c (main): Only run, if threads are enabled.
2004-02-26 17:20:01 +00:00
Sebastian Wilhelmi
ea9d13892e empty G_ATOMIC_MEMORY_BARRIER() definition for !G_THREADS_ENABLED
2004-02-26  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/gatomic.h: empty G_ATOMIC_MEMORY_BARRIER() definition for
	!G_THREADS_ENABLED

	* glib/gthread.h: Define g_once and
	g_static_mutex_get_mutex_impl_shortcut in terms of
	G_MEMORY_BARRIER, if defined and if we can inline.

	* configure.in: Remove double checked locking feature check.
2004-02-26 16:53:55 +00:00
Sebastian Wilhelmi
76c213543a Removed the PID niceness surrogate for thread priorities as requested by
2004-02-26  Sebastian Wilhelmi  <seppi@seppi.de>

	* configure.in, config.h.win32.in, glib/gthread.c: Removed the PID
	niceness surrogate for thread priorities as requested by Tim. It
	does more harm than good.

        * glib/tmpl/threads.sgml: Updated to reflect removal of the PID
	niceness surrogate for thread priorities.
2004-02-26 14:44:42 +00:00
Sebastian Wilhelmi
dbbb29f608 New files to implement atomic operations for different platforms. Fixes
2004-02-26  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/gatomic.c, glib/gatomic.h: New files to implement atomic
	operations for different platforms. Fixes bug #63621.

	* glib/glib.h: Include gatomic.h.

	* configure.in: Add test for assembler routines for atomic operations.

	* glib/Makefile.am: Add gatomic.c, gatomic.h.

	* tests/Makefile.am, tests/atomic-test.c: Unit test for atomic
	operations.

	* glib/glib-overrides.txt, glib/glib-sections.txt,
	glib/glib-docs.sgml, glib/tmpl/atomic_operations.sgml: Add docs
	for atomic operations.
2004-02-26 14:30:35 +00:00
Hans Breuer
fc9afe0d21 added g_hash_table_find and a bunch of g_queue_*
2003-02-26 Hans Breuer  <hans@breuer.org>

	* glib/glib.def : added g_hash_table_find and a
	bunch of g_queue_*

	* glib/gmain.c : make it compile on win32,
	child_wake_up_pipe replaced by semaphore like it is done
	for the other wake_up_pipe

	* config.h.win32.in : added HAVE_INT64_AND_I64
	* glibconfig.h.win32.in : G_MAXSIZE .. G_M??INT64,
	and typedef for GPid

	* test/env-test.c : don't let the local log function
	collide in namespace with standard C
2004-02-25 23:48:22 +00:00
Sebastian Wilhelmi
28a267e306 For the PID thread priorities surrogate use gettid instead of getpid. This
2004-02-25  Sebastian Wilhelmi  <seppi@seppi.de>

	* configure.in, glib/gthread.c: For the PID thread priorities
	surrogate use gettid instead of getpid. This also works with nptl
	(on linux-2.6), as well as with linuxthreads (on linux-2.4).
2004-02-25 13:23:14 +00:00
Sebastian Wilhelmi
79a29937af Add Since: 2.4, where due
2004-02-24  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/grand.c: Add Since: 2.4, where due
2004-02-24 21:17:10 +00:00
Owen Taylor
81e39b7858 === Released 2.3.3 ===
Tue Feb 24 14:09:21 2004  Owen Taylor  <otaylor@redhat.com>

        * === Released 2.3.3 ===

        * configure.in: Version 2.3.3, interface age 0.
2004-02-24 19:27:19 +00:00
Matthias Clasen
111b7fe5d6 Start of 2.3.3 section.
Mon Feb 23 22:24:00 2004  Matthias Clasen  <maclas@gmx.de>

	* NEWS: Start of 2.3.3 section.
2004-02-23 21:20:22 +00:00
Matthias Clasen
1c49b23e91 Set the gmodule suffix to 'a' for aix and use the aix gmodule
Sun Feb 22 02:28:43 2004  Matthias Clasen  <maclas@gmx.de>

	* configure.in: Set the gmodule suffix to 'a' for aix and
	use the aix gmodule implementation.  (#85930, Laurent Vivier)

	Bug #85930, Laurent Vivier:

	* gmodule-ar.c: Implementation of native module management for AIX.
	* gmoduleconf.h.in:
	* gmodule.c: Support gmodule-ar.c
2004-02-22 01:31:24 +00:00
Matthias Clasen
c0b5617ae9 New function to deep-copy a GNode and its children. (#93464, James M.
Sun Feb 22 00:47:04 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gnode.c (g_node_copy_deep): New function to deep-copy a
	GNode and its children.  (#93464, James M. Cape)
2004-02-21 23:56:54 +00:00
Soeren Sandmann
e21dadd6f3 Some documentation fixes.
Sat Feb 21 15:42:39 2004  Soeren Sandmann  <sandmann@daimi.au.dk>

	* glib/gqueue.c: Some documentation fixes.
2004-02-21 14:58:09 +00:00
Søren Sandmann Pedersen
511eba3364 Fix ChangeLog 2004-02-21 12:49:56 +00:00
Soeren Sandmann
a9bbf0f35d Extend GQueue API to match the GList API. (#118439).
Sat Feb 21 13:45:08 2004  Soeren Sandmann  <sandmann@daimi.au.dk>

	* glib/gqueue.[ch]: Extend GQueue API to match the GList
	API. (#118439).

	* tests/queue-test.c: Update test suite to cover the new API.
2004-02-21 12:48:08 +00:00
Tim Janik
ee4e622d37 applied patch from #131937 with slight renames. provides
Fri Feb 20 03:02:05 2004  Tim Janik  <timj@gtk.org>

        * glib/ghash.[hc]: applied patch from #131937 with slight
        renames. provides g_hash_table_find().
2004-02-20 02:05:36 +00:00
Tim Janik
defca980e4 applied patch from David Schleef <ds@schleef.org> which implements a
Fri Feb 20 02:39:03 2004  Tim Janik  <timj@gtk.org>

        * applied patch from David Schleef <ds@schleef.org> which implements
        a G_MODULE_BIND_LOCAL flag to g_module_open() to disable global
        symbol registration.
2004-02-20 01:41:00 +00:00
Tim Janik
c0930e2c71 for G_CAN_INLINE environments, inline g_string_append_c() for efficiency.
Thu Feb 19 18:40:01 2004  Tim Janik  <timj@gtk.org>

        * glib/gstring.[hc]: for G_CAN_INLINE environments, inline
        g_string_append_c() for efficiency. (vaguely based on #118707).
2004-02-19 17:42:00 +00:00
Sebastian Wilhelmi
ca87afd2e1 Forgot ChangeLog again......
Forgot ChangeLog again......
2004-02-19 09:14:09 +00:00
Matthias Clasen
e906108048 Include signal.h for SIGCHLD. (#134622, Damien Carbery)
Wed Feb 18 23:57:42 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gmain.c: Include signal.h for SIGCHLD.  (#134622, Damien
	Carbery)
2004-02-18 22:55:15 +00:00
Sebastian Wilhelmi
f18db7d2d4 Set context->wake_up_pipe only for G_THREADS_ENABLED.
2004-02-18  Sebastian Wilhelmi  <seppi@seppi.de>

	* glib/gmain.c (g_main_context_new): Set context->wake_up_pipe
	only for G_THREADS_ENABLED.
2004-02-18 09:14:17 +00:00
Manish Singh
fec8b1d45c Remove unnecessary STRIP_* definitions, and GNU make check. Really fixes
Sat Feb 14 11:05:26 2004  Manish Singh  <yosh@gimp.org>

        * configure.in: Remove unnecessary STRIP_* definitions, and GNU
        make check. Really fixes #134102.
2004-02-14 19:05:02 +00:00
Matthias Clasen
ad7581b792 Make the check for GNU make work when MAKE is a full path. (#134102, Julio
Sat Feb 14 02:11:08 2004  Matthias Clasen  <maclas@gmx.de>

	* configure.in: Make the check for GNU make work when MAKE is a
	full path.  (#134102, Julio M. Merino Vidal)
2004-02-14 01:08:15 +00:00
Matthias Clasen
61d0ff7edd Suppress xsltproc and xmlcatalog checks if enable_man=no. (#134091, Julio
Sat Feb 14 02:08:03 2004  Matthias Clasen  <maclas@gmx.de>

	* configure.in: Suppress xsltproc and xmlcatalog checks
	if enable_man=no.  (#134091, Julio M. Merino Vidal)
2004-02-14 01:04:47 +00:00
Matthias Clasen
540d02ba8b Wrap waitpid() as a GSource. This is a partial implementation of the "Unix
Sat Feb 14 01:21:34 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gmain.h:
	* glib/gmain.c (g_child_watch_source_new):
	* glib/gmain.c (g_child_watch_add):
	* glib/gmain.c (g_child_watch_add_full): Wrap waitpid() as a
	GSource. This is a partial implementation of the "Unix signal
	source".  (#50296, Jonathan R. Blandford)

	* configure.in: Add the necessary configury to typedef GPid
	appropriately.

	* tests/Makefile.am:
	* tests/child-test.c: Test child_watch sources.
2004-02-14 00:23:36 +00:00
Manish Singh
705ba7c15a Fix broken test for gsize formats.
Sat Feb  7 15:02:01 2004  Manish Singh  <yosh@gimp.org>

        * tests/type-test.c: Fix broken test for gsize formats.
2004-02-07 23:03:35 +00:00
Denis Lackovic
e56dd1b7e5 *** empty log message *** 2004-02-05 22:59:07 +00:00
Manish Singh
bbf110839c Add prototype for g_completion_complete_utf8().
Wed Feb  4 17:58:51 2004  Manish Singh  <yosh@gimp.org>

        * glib/gcompletion.h: Add prototype for g_completion_complete_utf8().

        * tests/completion-test.c: #include <string.h>
2004-02-05 01:58:47 +00:00
Tor Lillqvist
5889997512 Add g_completion_complete_utf8.
2004-02-05  Tor Lillqvist  <tml@iki.fi>

	* glib/glib.def: Add g_completion_complete_utf8.
2004-02-05 00:22:58 +00:00
Matthias Clasen
01fd2551d7 Weaken an g_assert() to a g_warning(), since apparently nothing in Posix
Thu Feb  5 01:19:12 2004  Matthias Clasen  <maclas@gmx.de>

	* tests/file-test.c (test_mkstemp): Weaken an g_assert() to a
	g_warning(), since apparently nothing in Posix forces mkstemp()
	to reject templates without any X's.  (#133397)
2004-02-05 00:17:28 +00:00
Matthias Clasen
dd394749f9 New function which works like g_completion_complete(), but strips a
Thu Feb  5 00:56:28 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gcompletion.c (g_completion_complete_utf8): New function which
	works like g_completion_complete(), but strips a trailing incomplete
	UTF-8 character from the prefix.  (#133313, Theppitak Karoonboonyanan)

	* tests/completion-test.c (main): Some GCompletion tests.

	* tests/Makefile.am: Add completion-test.
2004-02-04 23:54:17 +00:00
Tor Lillqvist
2c0de3525f Add g_strsplit_set.
2004-02-01  Tor Lillqvist  <tml@iki.fi>

	* glib/glib.def: Add g_strsplit_set.
2004-02-01 18:17:50 +00:00
Matthias Clasen
884d7c76ab Don't return FALSE from a pointer function. (#131472, Morten Welinder)
Sat Jan 31 03:13:56 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/garray.c (g_byte_array_remove_range): Don't return FALSE
	from a pointer function.  (#131472, Morten Welinder)
2004-01-31 02:12:06 +00:00
Noah Levitt
782188d539 Size compose_table correctly. (#123421, Simon Josefsson)
2004-01-30  Noah Levitt  <nlevitt@columbia.edu>

	* glib/gunicomp.h:
	* glib/gunidecomp.c:
	* glib/gen-unicode-tables.pl: Size compose_table correctly. (#123421,
        Simon Josefsson)

	* glib/gen-unicode-tables.pl: Get rid of some new warnings from perl
	5.8.1.
2004-01-30 23:20:16 +00:00
Manish Singh
0c5dee77e1 m4macros/glib-2.0.m4 quote AC_DEFUN macro names so automake 1.8 won't
Tue Jan 27 18:45:47 2004  Manish Singh  <yosh@gimp.org>

        * m4macros/glib-2.0.m4
        * m4macros/glib-gettext.m4: quote AC_DEFUN macro names so automake
        1.8 won't whine at us.
2004-01-28 02:46:30 +00:00
Matthias Clasen
326c025205 New function, a cross between g_strsplit() and strtok(). (#88329, Soeren
Wed Jan 28 01:39:21 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gstrfuncs.h:
	* glib/gstrfuncs.c (g_strsplit_set): New function, a cross
	between g_strsplit() and strtok().  (#88329, Soeren Sandmann)

	* tests/strfunc-test.c (main): Add g_strsplit_set() tests.
2004-01-28 00:37:46 +00:00
Matthias Clasen
d73f478058 Sigh, protect against pw->pw_gecos being "" as well. (#132317, Kaj-Michael
Fri Jan 23 22:49:52 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gutils.c (g_get_any_init): Sigh, protect against
	pw->pw_gecos being "" as well.  (#132317, Kaj-Michael Lang)
2004-01-23 21:49:21 +00:00
Tor Lillqvist
c1de91abbd Add new functions.
2004-01-23  Tor Lillqvist  <tml@iki.fi>

	* glib/glib.def: Add new functions.
2004-01-23 03:01:30 +00:00
Tor Lillqvist
876b7efdbd Don't include <unistd.h> unless HAVE_UNISTD_H. Include <process.h> on
2004-01-23  Tor Lillqvist  <tml@iki.fi>

	* glib/grand.c: Don't include <unistd.h> unless
	HAVE_UNISTD_H. Include <process.h> on G_OS_WIN32.
	(g_rand_new): Use getppid() only on G_OS_UNIX.
2004-01-23 02:10:46 +00:00
Owen Taylor
e009f72e5d === Released 2.3.2 ===
Thu Jan 22 15:16:11 2004  Owen Taylor  <otaylor@redhat.com>

        * === Released 2.3.2 ===
2004-01-22 20:20:31 +00:00
Owen Taylor
7ace455394 Add g_timer_continue(). (#98536, Tim-Philipp Müller)
Thu Jan 22 13:55:44 2004  Owen Taylor  <otaylor@redhat.com>

        * glib/gtimer.c: Add g_timer_continue().
        (#98536, Tim-Philipp Müller)

        * configure.in: Version 2.3.2, interface age 0.

        * NEWS: tweak, finish.
2004-01-22 19:56:28 +00:00
Matthias Clasen
6726db0afb Protect against pw->pw_gecos being NULL.
Thu Jan 22 20:50:55 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gutils.c (g_get_any_init): Protect against
	pw->pw_gecos being NULL.
2004-01-22 19:48:33 +00:00
Matthias Clasen
1107a9f41a Don't treat the Win32 user name like a gecos field, and when extracting a
Thu Jan 22 00:41:34 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gutils.c (g_get_any_init): Don't treat the Win32
	user name like a gecos field, and when extracting a real
	name from a gecos field, replace '&' by the capitalized
	user name (a traditional passwd feature).
	(#118973, reported by Soeren Boll Overgaard)
2004-01-21 23:41:46 +00:00
Matthias Clasen
e2d5240179 Start of 2.3.2 section.
Tue Jan 20 22:31:22 2004  Matthias Clasen  <maclas@gmx.de>

	* NEWS: Start of 2.3.2 section.
2004-01-20 21:28:55 +00:00
Matthias Clasen
d95fb32186 Forgot to fix this one.
Fri Jan 16 21:45:56 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gstring.c (g_string_ascii_up): Forgot to fix this one.
2004-01-16 20:44:03 +00:00
Matthias Clasen
6c43e9ac9f Move initialization of variables after g_return_val_if_fail. (#131564,
Thu Jan 15 22:35:04 2004  Matthias Clasen  <maclas@gmx.de>

	* glib/gstring.c (g_string_up):
	* glib/gstring.c (g_string_down):
	* glib/gstring.c (g_string_ascii_up):
	* glib/gstring.c (g_string_ascii_down): Move initialization of
	variables after g_return_val_if_fail.  (#131564, Olivier Poncet)
2004-01-15 21:33:58 +00:00
Manish Singh
31a1fedf68 Add G_MAXSIZE, define in terms of G_MAXUfoo.
Sun Jan 11 16:13:20 2004  Manish Singh  <yosh@gimp.org>

        * configure.in: Add G_MAXSIZE, define in terms of G_MAXUfoo.

        * tests/type-test.c: Add test for G_MAXSIZE.

        * glibconfig.h.win32.in: Cleanup, add some missing bits.
2004-01-12 00:16:18 +00:00
Manish Singh
3fa27319e9 #define _POSIX_SOURCE for SSIZE_MAX. Fixes #128853.
Sun Jan 11 16:05:35 2004  Manish Singh  <yosh@gimp.org>

        * glib/giounix.c: #define _POSIX_SOURCE for SSIZE_MAX. Fixes #128853.
2004-01-12 00:06:54 +00:00
Manish Singh
2dfeabdd9b 64-bit cleanliness fixes.
Sat Jan 10 00:11:12 2004  Manish Singh  <yosh@gimp.org>

        * glib/gutils.h (g_bit_nth_lsf,g_bit_nth_msf): 64-bit cleanliness
        fixes.

        * docs/reference/glib/tmpl/misc_utils.sgml: update to reflect the
        above take gulongs now. My docs suck, someone should revisit it.
2004-01-10 08:15:24 +00:00
George Lebl
80591652ff Add the init_by_array functionality from the reference implementation of
Fri Dec 19 11:49:21 2003  George Lebl <jirka@5z.com>

        * glib/grand.c
          glib/grand.h (g_rand_new) (g_rand_new_with_seed)
          (g_rand_new_with_seed_array) (g_rand_set_seed_array):  Add
          the init_by_array functionality from the reference implementation
          of the mersenne twister (mt19937ar.c) and change the naming
          to fit with the rest of the grand API.  New functions are
          g_rand_new_with_seed_array, g_rand_set_seed_array.  This is only
          reliable/tested for the 2.2 version of the seeding as that's what
          the reference implementation uses.  Also modify g_rand_new to
          get 4 longs from /dev/urandom since that will always be available
          anyway and we get more entropy and if /dev/urandom is unavailable
          use also 4 longs for seeding using secs, usecs, getpid and getppid.
          For version 2.0 use only a simple seed again but be more careful
          about seeding with secs/usecs in this case.

        * glib/grand.c
          glib/grand.h (g_rand_copy):  Add g_rand_copy function to copy the
          current state of the random number generator.

        * glib/grand.c (g_rand_new):  Add testing for EINTR when reading
          from /dev/urandom

        * tests/rand-test.c: add testing of the array seeding stuff against
          the reference implementation, plus add statistical sanity check
          to see that the values outputted are truly kind of random.  And
          check that g_rand_copy truly copies the state by checking a few
          terms.
2004-01-10 01:38:55 +00:00
Owen Taylor
8f7232c914 Check defined (__OPTIMIZE__) not __OPTIMIZE__. (Zack Rusin)
Tue Jan  6 15:38:30 2004  Owen Taylor  <otaylor@redhat.com>

        * glib/gutils.h: Check defined (__OPTIMIZE__) not
        __OPTIMIZE__. (Zack Rusin)
2004-01-06 20:45:21 +00:00
Murray Cumming
10bacd6058 Added a lowercase_name option, to be used next to the enum declaration,
2003-12-30  Murray Cumming  <murrayc@usa.net>

        * gobject/glib-mkenums.in: Added a lowercase_name option, to be used
        next to the enum declaration, where the flag option is already used,
        when it is not possible to guess where to put the underscores in the
        _get_type() function name, for instance for GNOMEVFSURIHide.
2003-12-30 10:42:57 +00:00
Matthias Clasen
e09de99eb5 New function to call a function for each element of a GPtrArray. (#114790)
Fri Dec 26 02:03:58 2003  Matthias Clasen  <maclas@gmx.de>

	* glib/garray.[hc] (g_ptr_array_foreach): New function to
	call a function for each element of a GPtrArray.  (#114790)

	* tests/array-test.c (main): Add a test for g_ptr_array_foreach().
2003-12-26 01:04:12 +00:00
Matthias Clasen
355807fff6 Quote macro names to support reading the file multiple times. (#125537)
Sun Dec 21 22:57:58 2003  Matthias Clasen  <maclas@gmx.de>

	* m4macros/glib-gettext.m4: Quote macro names to support
	reading the file multiple times.  (#125537)
2003-12-21 21:57:32 +00:00
Matthias Clasen
53e132ed39 Fix the locking of the mem_chunks list. (#127096, Balazs Scheidler)
Sun Dec 21 22:42:42 2003  Matthias Clasen  <maclas@gmx.de>

	* glib/gmem.c (g_mem_chunk_destroy): Fix the locking of the
	mem_chunks list.  (#127096, Balazs Scheidler)
2003-12-21 21:51:39 +00:00
Hans Breuer
aaa2ab083e make g_file_test(,G_FILE_TEST_IS_EXECUTABLE) return something useful on
2003-12-14  Hans Breuer  <hans@breuer.org>

	* glib/gfileutils.c : make g_file_test(,G_FILE_TEST_IS_EXECUTABLE)
	return something useful on win32, too.
2003-12-14 19:05:29 +00:00
Hans Breuer
35a6cff869 get_filename_charset() needs to return false for filenames not encoded in
2003-12-13  Hans Breuer  <hans@breuer.org>

	* glib/gconvert.c : get_filename_charset() needs to
	return false for filenames not encoded in utf-8,
	which is always true on win32

	* glibconfig.h.win32.in : (u)int64 modifier isn't the
	gcc 'll' but always the msvcrt one 'I64'

	* glib/glib.def : updated
2003-12-13 14:38:18 +00:00
Manish Singh
db16c1be2b change #elif with no expression to #else in G_STRFUNC definition. Thanks
Thu Dec 11 10:31:21 2003  Manish Singh  <yosh@gimp.org>

        * glib/gmacros.h: change #elif with no expression to #else in
        G_STRFUNC definition. Thanks to Damien Carbery, fixes #129101.
2003-12-11 18:31:46 +00:00
Owen Taylor
f2241f6e87 === Released 2.3.1 ===
Mon Dec  8 12:02:40 2003  Owen Taylor  <otaylor@redhat.com>

        * === Released 2.3.1 ===

        * NEWS: Further updates for 2.3.1.
2003-12-08 17:18:42 +00:00
Manish Singh
267031000f fix gint/gsize confusion.
Fri Dec  5 12:09:13 2003  Manish Singh  <yosh@gimp.org>

        * glib/gunidecomp.c (_g_utf8_normalize_wc): fix gint/gsize confusion.
2003-12-05 20:09:34 +00:00
Noah Levitt
45b1590923 Add hangul composition and decomposition to unicode normalization.
2003-12-04  Noah Levitt  <nlevitt@columbia.edu>

	* glib/gunidecomp.c: Add hangul composition and decomposition to
	unicode normalization. (#100456)

	* tests/unicode-normalize.c: Test hangul.
2003-12-04 19:47:52 +00:00
Matthias Clasen
04c96e8fa3 Fix for #103710, Mark Jones:
Tue Dec  2 02:29:41 2003  Matthias Clasen  <maclas@gmx.de>

	Fix for #103710, Mark Jones:

	* glib/gtypes.h (G_MAXINT64): Define G_{MIN,MAX,MAXU}INT{8,16,32,64}.
	* configure.in: Don't put G_{MIN,MAX,MAXU}INT64 in glibconfig.h.
2003-12-02 01:31:43 +00:00
Tim Janik
5d49a7caf7 handle NULL arguments gracefully.
Thu Nov 27 17:04:08 2003  Tim Janik  <timj@gtk.org>

        * glib/gstrfuncs.c (g_strconcat): handle NULL arguments
        gracefully.

        * glib/gmacros.h: defined G_STRFUNC, which (pretty) prints the
        current function (since G_STRLOC and G_GNUC_*FUNCTION became
        unusable with gcc-3.0).
2003-11-27 17:08:58 +00:00
Roozbeh Pournader
6e3b71aec3 Fixed a bad pointer comparison in g_ascii_strtod that came up in fa_IR
Wed Nov 26 16:45:16 2003  Roozbeh Pournader  <roozbeh@sharif.edu>

        * glib/gstrfuncs.c: Fixed a bad pointer comparison in
        g_ascii_strtod that came up in fa_IR locale (#126640, Behdad
        Esfahbod).

        * tests/strtod-test.c: Fixed the tests to catch the above.
2003-11-26 13:22:42 +00:00
15 2003 Andrew Lanoix
94d79f087b Bind inter-thread comminication sockets to INADDR_LOOPBACK instead of
Sat Nov 22 14:16:51.15 2003  Andrew Lanoix  <alanoix@umich.edu>

* glib/giowin32.c: Bind inter-thread comminication
sockets to INADDR_LOOPBACK instead of INADDR_ANY.
2003-11-22 19:28:04 +00:00
Manish Singh
b5ae75aa4a Added G_GSIZE_FORMAT and friends.
Thu Nov 20 15:09:40 2003  Manish Singh  <yosh@gimp.org>

        * configure.in: Added G_GSIZE_FORMAT and friends.

        * tests/printf-test.c
        * tests/testglib.c
        * tests/type-test.c: Add tests for the above.
2003-11-20 23:12:05 +00:00
Manish Singh
2b78955298 Use GUINT_TO_POINTER for g_thread_create data.
Mon Nov 17 17:28:10 2003  Manish Singh  <yosh@gimp.org>

        * tests/thread-test.c (test_g_thread_once): Use GUINT_TO_POINTER
        for g_thread_create data.
2003-11-18 01:29:36 +00:00
Matthias Clasen
0fd4b6d674 Add a NULL check to be consistent with the other g_utf8_ functions.
Sat Nov 15 23:00:57 2003  Matthias Clasen  <maclas@gmx.de>

	* glib/guniprop.c (g_utf8_casefold): Add a NULL check
	to be consistent with the other g_utf8_ functions.  (#121618,
	Tim-Philipp Müller)
2003-11-15 22:04:39 +00:00
Tor Lillqvist
d1a3a46ae8 Fix for MSVC build: Skip strtod-test, use correct glib libraries, with 2.0
2003-11-15  Tor Lillqvist  <tml@iki.fi>

	* tests/makefile.msc.in: Fix for MSVC build: Skip strtod-test, use
	correct glib libraries, with 2.0 in the names. (#126906, John
	Ehresman)
2003-11-15 03:08:57 +00:00
Matthias Clasen
f3a59d07bc Don't blindly set glib_cv_long_long_format to "ll" when using the included
Sat Nov 15 00:46:14 2003  Matthias Clasen  <maclas@gmx.de>

	* configure.in: Don't blindly set glib_cv_long_long_format to
	"ll" when using the included printf. As long as the native
	printf supports 64bit printing, use the native format.
	(#119525, Tor Lillquist)
2003-11-14 23:48:03 +00:00
Owen Taylor
9feec516be Version 2.3.1, interface age 0.
Wed Nov 12 15:06:27 2003  Owen Taylor  <otaylor@redhat.com>

        * configure.in: Version 2.3.1, interface age 0.

        * NEWS: Update for 2.3.1.
2003-11-12 20:28:35 +00:00
Mark McLoughlin
57f22f15be re-work to retain a copy of the cached charset rather than the actual
2003-11-07  Mark McLoughlin  <mark@skynet.ie>

        * glib/gconvert.c: (get_filename_charset): re-work to
        retain a copy of the cached charset rather than the
        actual return value from g_get_charset (which may
        change). Also, re-initialize the cache if it does
        change. See bug #126454.
2003-11-09 13:17:23 +00:00
Matthias Clasen
42f0cca05a Replacement for have_broken_filenames() which consults the environment
Thu Nov  6 00:04:46 2003  Matthias Clasen  <maclas@gmx.de>

	* glib/gconvert.c (get_filename_charset): Replacement for
	have_broken_filenames() which consults the environment variable
	G_FILENAME_ENCODINGS in addition to G_BROKEN_FILENAMES.
	* glib/gconvert.c (g_filename_from_utf8):
	* glib/gconvert.c (g_filename_to_utf8):
	* glib/gconvert.c (_g_convert_thread_init): Use
	get_filename_charset() instead of have_broken_filenames().
2003-11-05 23:05:49 +00:00
Matthias Clasen
2807b4e6eb New headers defining common gettext-support macros.
Wed Nov  5 22:05:19 2003  Matthias Clasen  <maclas@gmx.de>

	* glib/gi18n-lib.h:
	* glib/gi18n.h: New headers defining common gettext-support
	macros.

	* glib/Makefile.am (glibsubinclude_HEADERS): Add gi18n.h
	and gi18n-lib.h.

	* glib/gstrfuncs.h:
	* glib/gstrfuncs.c (g_strip_context): Auxiliary function for
	the implementation of Q_().
2003-11-05 21:07:47 +00:00
Morten Welinder
36715ffb1e Make it compile. (#119337, self.)
2003-11-05  Morten Welinder  <terra@gnome.org>

	* glib/garray.c (g_ptr_array_remove_range): Make it compile.
	(#119337, self.)
2003-11-05 17:15:24 +00:00
Morten Welinder
3b2f74d188 Handle the case where the to-be-inserted string is a substring of the
2003-11-05  Morten Welinder  <terra@gnome.org>

	* glib/gstring.c (g_string_insert_len): Handle the case where the
	to-be-inserted string is a substring of the target string.
	(g_string_assign): Handle "s = s;".
	(#114260, self.)
2003-11-05 16:24:44 +00:00
Matthias Clasen
76433d5365 Fix 64bit printing for MSVC builds (#119292, Hans Breuer):
Sun Nov  2 01:47:31 2003  Matthias Clasen  <maclas@gmx.de>

	Fix 64bit printing for MSVC builds (#119292, Hans Breuer):

	* configure.in (HAVE_INT64_AND_I64): Define for MSVC to
	include support for printing __int64 with format %I64 in
	the gnulib printf wrappers.
	* glib/gnulib/printf-args.h (enum arg_type): Add TYPE_INT64
	and TYPE_UINT64.
	* glib/gnulib/printf-args.h (struct argument): Add a_int64 and
	a_uint64 members.
	* glib/gnulib/printf-args.c (printf_fetchargs): Support
	TYPE_INT64 and TYPE_UINT64.
	* glib/gnulib/printf-parse.c (printf_parse): Parse I64 format
	modifier and map formats to TYPE_INT64.
	* glib/gnulib/vasnprintf.c (vasnprintf): Print TYPE_INT64 with
	format modifier I64.
	* glib/gnulib/README: Document the __int64 support.
2003-11-02 00:54:02 +00:00
Owen Taylor
3f1a49ea41 Set the return value from the result of g_main_context_check() (after we
Sat Nov  1 08:45:38 2003  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c (g_main_context_iterate): Set the
        return value from the result of g_main_context_check()
        (after we poll) rather than g_main_context_prepare.
        (#121675, Padraig O'Briain)
2003-11-01 13:57:48 +00:00
Matthias Clasen
4dbdd6e05e Remove the semicolon from the definition of g_once(), so that
Fri Oct 31 00:13:53 2003  Matthias Clasen  <maclas@gmx.de>

	* configure.in: Remove the semicolon from the definition of
	g_once(), so that GPOINTER_TO_INT (g_once (...)) works.
2003-10-30 23:17:57 +00:00
Matthias Clasen
c582b7ad60 Change the %e tests to not check for actual string equality, but rather
Tue Oct 28 23:38:30 2003  Matthias Clasen  <maclas@gmx.de>

	* tests/printf-test.c: Change the %e tests to not check for
	actual string equality, but rather equality under g_ascii_strtod(),
	since the number of leading digits in the exponent seems to
	be not exactly prescribed by SUS.
2003-10-28 22:40:51 +00:00
Owen Taylor
05d097adb6 === Released 2.3.0 ===
Fri Oct 24 17:09:04 2003  Owen Taylor  <otaylor@redhat.com>

        * === Released 2.3.0 ===

        * NEWS: Small update.
2003-10-24 21:28:34 +00:00