Commit Graph

2256 Commits

Author SHA1 Message Date
Stefan Westerfeld
896d38706b inserted casts for C++.
Mon Sep  8 00:31:10 2003  Stefan Westerfeld  <stefan@space.twc.de>

        * glib/gbsearcharray.h: inserted casts for C++.
2003-09-07 22:36:58 +00:00
Tim Janik
558507bc5a added support for a "default vtable" per interface, that interface vtables
Tue Sep  2 19:37:21 2003  Tim Janik  <timj@gtk.org>

        * gtype.[hc]: added support for a "default vtable" per interface,
        that interface vtables are initialized from.
        the default vtable is initialized and finalized through class_init,
        class_finalize and class_data from the interfaces GTypeInfo struct.
        (type_data_last_unref_Wm): unload child plugin before unreffing
        parent type.

        testifaceinit.c: minor fixups. fixed up base_init() assertions, since
        with a default vtable, base_init() may be called multiple times.
        added default initializer to iface1.
2003-09-02 17:57:22 +00:00
Tim Janik
de059b53bc fix iterating over fundamental types.
Tue Sep  2 14:53:41 2003  Tim Janik  <timj@gtk.org>

        * gobject-query.c (main): fix iterating over fundamental types.

        * gtype.c: applied patch from owen which keeps internal
        class initialization state to maintain class and interface
        initialization happen in the order of:
        1. class' base_init
        2. interface' base_init
        =  interfaces added after here are immediately base_init-ialized
        3. class_init
        4. Interface_init
        =  interfaces added here are immediately Interface_init-ialized
2003-09-02 12:58:23 +00:00
Manish Singh
056041aab9 removed stray change from previous commit.
Wed Aug 27 19:53:26 2003  Manish Singh  <yosh@gimp.org>

        * gobject.c: removed stray change from previous commit.
2003-08-28 02:55:58 +00:00
Manish Singh
7dbe422777 shut up cvs 2003-08-28 02:20:17 +00:00
Matthias Clasen
3155dfd3dc Fix a C99ism. (#120821, Thomas Klausner)
2003-08-28  Matthias Clasen  <maclas@gmx.de>

	* tests/patterntest.c (verbose): Fix a C99ism.  (#120821, Thomas
	Klausner)
2003-08-27 22:27:41 +00:00
Owen Taylor
6bd3d8bcf6 Add a detailed test case for interface initialization, testing the ability
Wed Aug 27 01:25:40 2003  Owen Taylor  <otaylor@redhat.com>

        * Makefile.am testifaceinit.c: Add a detailed test case
        for interface initialization, testing the ability to
        add interfaces during class initialization and the ordering
        of interface base_init, class init, and interface_init.
        (Expected to fail at the moment.)
2003-08-27 05:28:39 +00:00
Manish Singh
d2cd289bf2 fix typo in last commit, cast to GTypeValueTable * to get rid of const
Mon Aug 25 14:51:46 2003  Manish Singh  <yosh@gimp.org>

        * gtypemodule.c (g_type_module_register_type): fix typo in last
        commit, cast to GTypeValueTable * to get rid of const warning.
2003-08-25 22:02:22 +00:00
Tor Lillqvist
e2797b3525 Avoid UNLOCKing the critical section twice, which might cause a hang.
2003-08-25  Tor Lillqvist  <tml@iki.fi>

	* glib/giowin32.c (read_thread): Avoid UNLOCKing the critical
	section twice, which might cause a hang. (#120653)

	* glib/giowin32.c (g_io_channel_unix_new): Warn if fd is both a
	valid file descriptor and socket.
2003-08-25 21:37:57 +00:00
Owen Taylor
cd91400c1c add bug number 2003-08-25 18:42:38 +00:00
Owen Taylor
5e88cedf02 Clarify docs on the return. Fix a memory leak if a type with a value table
Mon Aug 25 14:16:48 2003  Owen Taylor  <otaylor@redhat.com>

        * gtypemodule.c (g_type_module_register_type): Clarify
        docs on the return. Fix a memory leak if a type with a
        value table is reloaded.
2003-08-25 18:23:58 +00:00
Owen Taylor
23137b79d9 Escape control characters in g_logv() output. (#108287, Christian Biere)
Mon Aug 25 12:34:36 2003  Owen Taylor  <otaylor@redhat.com>

        * glib/gmessages.c: Escape control characters in g_logv() output.
        (#108287, Christian Biere)
2003-08-25 16:36:03 +00:00
Owen Taylor
2afc40f3a6 When DISABLE_MEM_POOLS is set, loop through and free the poll records
Mon Aug 25 12:17:20 2003  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c (g_main_context_unref_and_unlock):
        When DISABLE_MEM_POOLS is set, loop through and free
        the poll records explicitely, since g_mem_chunk_destroy()
        won't do it. (#118121, Morten Welinder)
2003-08-25 16:20:41 +00:00
Kjartan Maraas
610240c411 Flush 2003-08-23 11:41:46 +00:00
Samel Jn Gunnarsson
0b771a2441 Added "is" to ALL_LINGUAS.
2003-08-23  Samel Jn Gunnarsson  <sammi@techattack.nu>

	* configure.in: Added "is" to ALL_LINGUAS.
2003-08-23 01:05:02 +00:00
Richard Allen
9159c7190b Added Icelandic translation 2003-08-20 16:14:25 +00:00
Tor Lillqvist
200bb7f771 [Win32] Make the fatal error message box easier to notice with
2003-08-19  Tor Lillqvist  <tml@iki.fi>

	* glib/gmessages.c (g_logv): [Win32] Make the fatal error message
	box easier to notice with MB_SETFOREGROUND. Also use MB_ICONERROR
	to get a nice stop-sign icon.
2003-08-19 19:12:07 +00:00
Owen Taylor
9d8e67597c Add $INTLLIBS to $LIBS temporarily, not -lintl. (Problem with fix for
Tue Aug 19 09:42:06 2003  Owen Taylor  <otaylor@redhat.com>

        * m4macros/glib-gettext.m4: Add $INTLLIBS to $LIBS
        temporarily, not -lintl. (Problem with fix for
        #119171, pointed out by James Henstridge)
2003-08-19 13:45:33 +00:00
Tim Janik
105adb9a35 check private instance data after initialization.
Tue Aug 19 05:21:04 2003  Tim Janik  <timj@gtk.org>

        * testgobject.c (main): check private instance data after
        initialization.

        * gtype.c: for instances with private data, store the real class
        pointer in a bsearch array during class initialization.
        (g_type_instance_get_private): fetch the real class of
        an instance from the bsearch array if necessary.
2003-08-19 03:25:46 +00:00
Tim Janik
808a282944 license change, no restrictions are made in the new license at all, the
Tue Aug 19 03:55:29 2003  Tim Janik  <timj@gtk.org>

        * glib/gbsearcharray.h: license change, no restrictions are made
        in the new license at all, the implmentation is simply provided
        "as is" to allow copy-pasting the code into any third-party app.
        naturally, the implementation is self-contained within the header
        file to allow this.
        default to non-shrinking behaviour, allow users to request shrinking
        via G_BSEARCH_ARRAY_AUTO_SHRINK.
        creation, deletion functions are now named g_bsearch_array_create()
        and g_bsearch_array_free().
        fixed const in prototypes, removed cruft.
        (g_bsearch_array_insert): take only three arguments, do nothing if the
        node to insert is already there.
        (g_bsearch_array_replace): insert or replace if the node is already
        there.
        (g_bsearch_array_remove): remove nodes by index, the index of a node
        can be found via g_bsearch_array_get_index().
        removed other g_bsearch_array_remove*() variants.
        (g_bsearch_array_lookup): minor optimizations.
        (g_bsearch_array_lookup_sibling): return nodes on mismatches.

        * glib/gbsearcharray.c: removed.
2003-08-19 02:16:00 +00:00
Tim Janik
6d6e68f3e4 adapt to new gbsearcharray.h code. (g_value_register_transform_func): turn
Tue Aug 19 04:08:14 2003  Tim Janik  <timj@gtk.org>

        * gvalue.c: adapt to new gbsearcharray.h code.
        (g_value_register_transform_func): turn transform function
        replacement into a valid operation.

        * gsignal.c: adapt to new gbsearcharray.h code.

        * gboxed.c: adapt to new gbsearcharray.h code.
2003-08-19 02:15:40 +00:00
Tim Janik
779c44cdfb added optimizations to skip NOP signal emissions.
Tue Aug 19 01:31:28 2003  Tim Janik  <timj@gtk.org>

        * gsignal.c: added optimizations to skip NOP signal emissions.
2003-08-18 23:32:17 +00:00
Kjartan Maraas
b1b9636b73 Update Norwegian translation.
2003-08-18  Kjartan Maraas  <kmaraas@gnome.org>

	* no.po: Update Norwegian translation.
2003-08-18 20:50:47 +00:00
Metin Amiroff
4c78995337 Updated Azerbaijani translation.
2003-08-18  Metin Amiroff <metin@karegen.com>

	* az.po: Updated Azerbaijani translation.
2003-08-18 10:13:33 +00:00
Tor Lillqvist
55d624d80c Fix #117925 (Dov Grobgeld):
2003-08-16  Tor Lillqvist  <tml@iki.fi>

	Fix #117925 (Dov Grobgeld):

	* glib/gutils.c (g_find_program_in_path, g_basename,
	g_path_get_basename, g_path_is_absolute, g_path_skip_root,
	g_path_get_dirname, g_get_any_init): On Win32, look also for
	slashes ('/') as pathname separators.

	* glib/gfileutils.c (g_file_open_tmp): Ditto. If the template
	contains a pathname separator, include the actual one in the error
	message, instead of always the canonical one.

	(g_build_filename): Separate implementation on Win32 that looks
	for either slash or backslash. Document Unix/Windows differences.

	* tests/testglib.c
	* tests/strfunc-test.c: Test above functionality on Win32.
2003-08-16 19:45:25 +00:00
Danilo Šegan
ed23bef565 Updated Serbian translation.
2003-08-16  Danilo Šegan  <dsegan@gmx.net>

	* sr.po, sr@Latn.po: Updated Serbian translation.
2003-08-15 23:47:33 +00:00
Tor Lillqvist
3f3bb7fef3 [Win32] Don't exceed handle array bounds. Warn if there would be too many
2003-08-15  Tor Lillqvist  <tml@iki.fi>

	* glib/gmain.c (g_poll): [Win32] Don't exceed handle array
	bounds. Warn if there would be too many handles to wait
	for. (WaitForMultipleObjects() has a relatively low limit of 64
	handles. The Win32 IO channel code should be fixed not to need to
	wait for one handle per file or socket being watched. Later.)
2003-08-15 05:06:16 +00:00
Anders Carlsson
12eae9a669 Add .cvsignore 2003-08-13 08:39:41 +00:00
Tor Lillqvist
a44c1da1c4 glib/Makefile.am gmodule/Makefile.am gobject/Makefile.am Use srcdir also
2003-08-13  Tor Lillqvist  <tml@iki.fi>

	* glib/Makefile.am
	* gmodule/Makefile.am
	* gobject/Makefile.am
	* gthread/Makefile.am: Use srcdir also in references to the .def
	files. (#118885, Jeff Bonggren)
2003-08-13 00:24:21 +00:00
Tor Lillqvist
2b553df50d Drop the Win32-specific implementation. It used WideCharToMultiByte(),
2003-08-12  Tor Lillqvist  <tml@iki.fi>

	* glib/gconvert.c (g_locale_from_utf8): Drop the Win32-specific
	implementation. It used WideCharToMultiByte(), which is broken as
	it stores unconvertable characters as fallback characters
	(question marks) in the destination string without being able to
	tell how much of the conversion succeeded. Using g_convert() like
	on Unix is better and simpler. (#117872)

	(g_locale_to_utf8): No need for the Win32-specific implementation
	here, either.

	(have_broken_filenames): Define as TRUE on Win32.

	(g_filename_to_utf8, g_filename_from_utf8): Drop Win32 ifdefs. As
	have_broken_filenames() now is defined TRUE on Win32, works as
	before.
2003-08-13 00:13:02 +00:00
Matthias Clasen
42dcec41de Wrap to 80 columns. 2003-08-11 20:49:32 +00:00
Matthias Clasen
79bdb0d572 Copy newer versions of JH_CHECK_XML_CATALOG and JH_PATH_XML_CATALOG from
* acinclude.m4: Copy newer versions of JH_CHECK_XML_CATALOG and JH_PATH_XML_CATALOG from
	gtk-doc to enable configuring without xmlcatalog in PATH.  (#119115)
2003-08-10 22:24:17 +00:00
Tor Lillqvist
6489e6a5d5 Don't use a cache of variable name to value mappings on Win32, as that
2003-08-10  Tor Lillqvist  <tml@iki.fi>

	* glib/gutils.c (g_getenv): Don't use a cache of variable name to
	value mappings on Win32, as that breaks g_setenv() and
	g_unsetenv(). Only call ExpandEnvironmentStrings() if necessary,
	and in that case return a quarkified string. It is still
	questionable how necessary expanding embedded environment variable
	references is. Possibly the whole Win32-specific g_getenv()
	implementation could be removed. (#119520)
2003-08-10 08:04:10 +00:00
Tor Lillqvist
6fb380e374 Add g_once_impl.
2003-08-08  Tor Lillqvist  <tml@iki.fi>

	* glib/glib.def: Add g_once_impl.
2003-08-10 01:54:02 +00:00
Tor Lillqvist
63d5300574 Fix syntax error in the !HAVE_SETENV case.
2003-08-08  Tor Lillqvist  <tml@iki.fi>

	* glib/gutils.c (g_setenv): Fix syntax error in the !HAVE_SETENV
	case.
2003-08-08 20:38:15 +00:00
Matthias Clasen
29606d90b0 Improve the wording of the warning for invalid
values.  (#117246, Mariano Suarez-Alvarez)
2003-08-08 19:47:35 +00:00
Matthias Clasen
18042ea064 Remove a test for getenv() behaviour which isn't specified by SUS and
2003-08-08  Matthias Clasen  <maclas@gmx.de>

	* tests/env-test.c (main): Remove a test for getenv() behaviour which isn't specified by SUS
	and doesn't work on Solaris.
2003-08-08 19:28:24 +00:00
Matthias Clasen
96838a7a88 Add tests for '=' in names and values.
2003-08-07  Matthias Clasen  <maclas@gmx.de>

	* tests/env-test.c: Add tests for '=' in names and values.

	* glib/gutils.c (g_setenv, g_unsetenv): Check that the variable name doesn't contain '='. Add a
	declaration for environ.  (#119338)
2003-08-07 21:51:38 +00:00
Matthias Clasen
4d2921959e Tighten the snprintf() test to check behaviour on zero-size buffers.
2003-08-07  Matthias Clasen  <maclas@gmx.de>

	* acinclude.m4: Tighten the snprintf() test to check behaviour on zero-size buffers.  (#106091)
2003-08-07 20:48:10 +00:00
Matthias Clasen
d695d28b1b Specify test strings in UTF-8, remove all charset conversion. Replace the
2003-08-07  Matthias Clasen  <maclas@gmx.de>

	* tests/patterntest.c: Specify test strings in UTF-8, remove all charset conversion.
	Replace the NOISY define by a cmdline arg --noisy.   (#115757)
2003-08-07 19:39:36 +00:00
Owen Taylor
ba0c0d91f7 Set $LIBS to include -lintl when checking for dcgettext and
Thu Aug  7 15:01:09 2003  Owen Taylor  <otaylor@redhat.com>

        * m4macros/glib-gettext.m4: Set $LIBS to include
        -lintl when checking for dcgettext and
        _nl_msg_cat_cntr. (Tim Mooney, #119171)
2003-08-07 19:10:41 +00:00
Owen Taylor
b51c0d2f70 Make the default priority for idle sources G_PRIORITY_DEFAULT_IDLE as
Thu Aug  7 14:15:44 2003  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c (g_idle_source_new): Make the default priority
        for idle sources G_PRIORITY_DEFAULT_IDLE as anybody would
        expect and document that. (#114461, reported by Andy Wingo)
2003-08-07 18:19:23 +00:00
Noah Levitt
f1d488de09 Add test for special case not at inital position in the string, the bug
2003-08-06  Noah Levitt  <nlevitt@columbia.edu>

	* tests/casemap.txt:
	* tests/gen-casemap-txt.pl: Add test for special case not at inital
	position in the string, the bug just fixed. (#118957)
2003-08-06 20:28:33 +00:00
Owen Taylor
b9312d57c5 Add check for instance private usage within in instance_init. (Currently
Wed Aug  6 09:57:14 2003  Owen Taylor  <otaylor@redhat.com>

        * testgobject.c (test_signal_accumulator): Add check
        for instance private usage within in instance_init.
        (Currently will fail.)
2003-08-06 14:33:20 +00:00
Noah Levitt
ffa5f95327 Fix small mistake in last commit. (still falls in the same Changelog entry) (#118957) 2003-08-06 01:25:46 +00:00
Noah Levitt
8fa63e43c8 Get rid of "len" parameter to output_special_case and output_marks, and
2003-08-05  Noah Levitt  <nlevitt@columbia.edu>

	* glib/guniprop.c: Get rid of "len" parameter to output_special_case
	and output_marks, and make them work more like g_unichar_to_utf8,
	fixing a bug in the process. (#118957)
2003-08-06 01:08:46 +00:00
Hans Breuer
1fd50a1454 for msvc build
2003-08-05  Hans Breuer  <hans@breuer.org>

	* glib/gnulib/makefile.msc : (new file) for msvc build

	* glib/gnulib/vasnprintf.c : use glib/galloc.h

	* glib/gnulib/printf.h : #include <stdio.h> for FILE*

	* glib/makefile.msc.in : replace trio with gnulib

	* glib/glib.def : updated externals

	* glib/guniprop.c : fix for guniprop.c(582) : error C2082:
	redefinition of formal parameter 'len'
2003-08-05 22:21:19 +00:00
Matthias Clasen
10d02e3aef Add note about in-place editing to g_strdelimit() doc.
(#118875, Thomas Vander Stichele)
2003-08-05 21:35:55 +00:00
Noah Levitt
479928953b We do handle > BMP now, so test it.
2003-08-04  Noah Levitt  <nlevitt@columbia.edu>

	* tests/unicode-normalize.c: We do handle > BMP now, so test it.
2003-08-05 03:41:34 +00:00
Sajith VK
1cb5f0a11d Retrying? 2003-08-02 14:54:17 +00:00