Commit Graph

1163 Commits

Author SHA1 Message Date
Manish Singh
55a39b8033 avoid creating negative values out of unsigned values using MAX, check to
Fri Oct 18 13:41:30 2002  Manish Singh  <yosh@gimp.org>

        * glib/giochannel.c (g_io_channel_read_line_backend): avoid
        creating negative values out of unsigned values using MAX,
        check to see if the result would be positive before doing
        the calculation.
2002-10-18 20:43:56 +00:00
Manish Singh
ac1080ee3b use gsize instead of int where appropriate (64-bit cleanliness fix).
Tue Oct 15 15:28:47 2002  Manish Singh  <yosh@gimp.org>

        * tests/iochannel-test.c: use gsize instead of int where appropriate
        (64-bit cleanliness fix). Removed leftover line_term cruft.
2002-10-15 22:39:16 +00:00
Manish Singh
d1f37d5053 add -DG_DISABLED_DEPRECATED
Tue Oct 15 15:07:45 2002  Manish Singh  <yosh@gimp.org>

        * gmodule/Makefile.am gobject/Makefile.am gthread/Makefile.am:
        add -DG_DISABLED_DEPRECATED

        * tests/gio-test.c tests/mainloop-test.c tests/string-test.c
        tests/testglib.c test/tree-test.c tests/unicode-collate.c
        tests/unicode-normalize.c: Deprecation cleanup
2002-10-15 22:16:57 +00:00
Owen Taylor
f861d72bb2 Fix a memory leak. (#94550, Sebastian Rittau)
Mon Oct 14 15:51:05 2002  Owen Taylor  <otaylor@redhat.com>

        * glib/gdate.c (g_date_fill_parse_tokens): Fix a memory
        leak. (#94550, Sebastian Rittau)
2002-10-14 22:18:16 +00:00
Owen Taylor
b47574aee6 Make prefix argument const. (#91662, Gustavo Carneiro)
Mon Oct 14 15:36:11 2002  Owen Taylor  <otaylor@redhat.com>

        * glib/gcompletion.[ch] (g_completion_complete): Make
        prefix argument const. (#91662, Gustavo Carneiro)
2002-10-14 19:38:30 +00:00
Owen Taylor
27dc698317 Fix a minor memory leak.
Mon Oct 14 15:32:14 2002  Owen Taylor  <otaylor@redhat.com>

        * tests/mainloop-test.c (adder_response): Fix a minor memory
        leak.
2002-10-14 19:33:37 +00:00
Tim Janik
f650a78e8b fix comment. (g_ascii_strtoull): new function, acting like strtoull(3) in
Sat Oct 12 21:30:41 2002  Tim Janik  <timj@gtk.org>

        * merged up from glib-2-0:

        * glib/gstrfuncs.c (g_ascii_strtod): fix comment.
        (g_ascii_strtoull): new function, acting like strtoull(3) in the C
        locale.

        * glib/gscanner.[hc]: fix 32bit issues with integer parsing and
        support storing 64bit values in GTokenValue by
        using g_ascii_strtoull().
2002-10-12 19:37:48 +00:00
Soeren Sandmann
6b8ab1206e Documentation fixes: #71778, Owen Taylor; #85095, Bill Janssen, Owen
Sat Oct 12 12:34:22 2002  Soeren Sandmann  <sandmann@daimi.au.dk>

	* glib/gtree.c (g_tree_search), glib/gspawn.c
	(g_spawn_async_with_pipes):

	Documentation fixes: #71778, Owen Taylor; #85095, Bill Janssen,
	Owen Taylor.
2002-10-12 10:36:45 +00:00
Tim Janik
41c5704578 if input_name is NULL, print out "<memory>" instead of completely skipping
Thu Oct 10 23:27:02 2002  Tim Janik  <timj@gtk.org>

        * glib/gscanner.c (g_scanner_msg_handler): if input_name is NULL,
        print out "<memory>" instead of completely skipping input specification
        and thusly loosing error line information.
2002-10-10 21:26:25 +00:00
Manish Singh
f92ba4ece8 use gsize instead of int where appropriate (64-bit cleanliness fix)
Sun Sep 29 12:15:44 2002  Manish Singh  <yosh@gimp.org>

        * tests/mainloop-test.c: use gsize instead of int where appropriate
        (64-bit cleanliness fix)
2002-09-29 19:16:31 +00:00
Tor Lillqvist
dd373b4831 Instead of forcing -fnative-struct into CFLAGS when using gcc for Win32,
2002-09-29  Tor Lillqvist  <tml@iki.fi>

	* configure.in: Instead of forcing -fnative-struct into CFLAGS
	when using gcc for Win32, check for gcc version 3.x which uses
	-mms-bitfields instead. Also check if either of these switches is
	actually available at all, and warn if not. Thanks to Soren
	Andersen for the inspiration.
2002-09-28 23:52:52 +00:00
Tor Lillqvist
a6d23a4a54 Say we require autoconf 2.52 as that is what configure.in does.
2002-09-29  Tor Lillqvist  <tml@iki.fi>

	* HACKING: Say we require autoconf 2.52 as that is what
	configure.in does.
2002-09-28 22:15:05 +00:00
Arvind Samptur
0ce0882772 when the child fails we need to reap it to avoid a zombie. This would
2002-09-23  Arvind Samptur <arvind.samptur@wipro.com>
        * glib/gspawn.c (fork_exec_with_pipes) : when the child fails
        we need to reap it to avoid a zombie. This would
        happen in case of g_spawn_sync. Fixes #92658
2002-09-23 06:45:10 +00:00
Matthias Clasen
340a3e809d Don't print scanner->input_name when it is NULL. (#93752)
* glib/gscanner.c (g_scanner_msg_handler): Don't print
	scanner->input_name when it is NULL.  (#93752)
2002-09-20 21:35:50 +00:00
Havoc Pennington
3afc93f1aa automake 1.4
2002-09-06  Havoc Pennington  <hp@redhat.com>

	* autogen.sh: automake 1.4
2002-09-06 19:28:28 +00:00
Soeren Sandmann
4acacec101 Documentation fixes: (#75255, Martin Schulze; #76104, Daryll Strauss)
2002-09-01  Soeren Sandmann  <sandmann@daimi.au.dk>

	* docs/reference/glib/tmpl/datalist.sgml, glib/gmain.c:

	Documentation fixes: (#75255, Martin Schulze; #76104, Daryll Strauss)
2002-09-01 13:04:02 +00:00
Tor Lillqvist
5f7945dea9 Don't link with -lwsock32 on Cygwin (#91696, Masahiro Sakai).
2002-08-26  Tor Lillqvist  <tml@iki.fi>

	* configure.in (G_LIBS_EXTRA): Don't link with -lwsock32 on
	Cygwin (#91696, Masahiro Sakai).
2002-08-26 19:39:28 +00:00
Hidetoshi Tajima
ffe04247cc validate 'len' argument properly for the case that input string is not
* glib/gconvert.c (strdup_len): validate 'len' argument properly
	for the case that input string is not null-terminated. (#91222)
2002-08-20 23:03:17 +00:00
Gustavo Noronha Silva
a086c90012 new translation 2002-08-10 18:12:14 +00:00
Matthias Clasen
e7d3a38f48 Use g_return_val_if_fail, no g_return_if_fail.
* glib/gmarkup.c (g_markup_parse_context_get_element):
	Use g_return_val_if_fail, no g_return_if_fail.
2002-08-07 22:15:43 +00:00
Sebastian Wilhelmi
659fd4113b Factor out g_main_context_init_pipe from g_main_context_new to initialize
2002-08-06  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* glib/gmain.c: Factor out g_main_context_init_pipe from
	g_main_context_new to initialize the wakeup pipe of a
	context. Call that function from g_main_context_new if threads are
	initialized and for all contexts when threads are initialized
	in g_main_thread_init. (#86872)

	* gthread/gthread-impl.c: Call g_main_thread_init. (#86872)
2002-08-06 14:50:52 +00:00
Sebastian Wilhelmi
3faf95913d Set the normal PID surrogate priority according to getpid() to avoid
2002-08-06  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* glib/gthread.c: Set the normal PID surrogate priority according
	to getpid() to avoid errors for niced processes. (#86116)

	* gthread/gthread-impl.c, gthread/gthread-posix.c,
	gthread/gthread-solaris.c: Do the same for the posix/dce
	implementation. Solaris still needs to set priority of the main
	thread, because all unbound threads will schedule according to
	that value and it defaults to 0 (the minimal value).
2002-08-06 13:31:26 +00:00
Owen Taylor
8dd32f5703 hu Jul 25 14:23:15 2002 Owen Taylor <otaylor@redhat.com>
* glib/gfileutils.c: Clarify the behavior of g_build_path()
        for empty elements and for leading and trailing copies
        of the separator in the docs.

        * glib/gfileutils.c: Fix problems with leading elements
        consisting only of "/" characters. (#85928, Guillaume Chazarain)

        * tests/strfunc-test.c (main): Add more test cases
        for g_build_filename().
2002-07-26 19:59:07 +00:00
Matthias Clasen
1bb885b3b2 New function to revert a utf8 string. Gone, replaced by g_utf8_strreverse.
* glib/gunicode.h:
	* glib/gutf8.c (g_utf8_strreverse): New function to revert
	a utf8 string.
	* glib/gpattern.c (g_utf8_reverse): Gone, replaced by
	g_utf8_strreverse.  (#87725)
2002-07-26 19:48:02 +00:00
Owen Taylor
289ad03afd Fix docs for @str_return to conform to the main docs and the
Thu Jul 25 20:57:20 2002  Owen Taylor  <otaylor@redhat.com>

        * glib/giochannel.c (g_io_channel_read_line): Fix
        docs for @str_return to conform to the main docs
        and the implementation as to whether the terminator
        is included. (#87964, Jacob Berkman)
2002-07-26 00:59:07 +00:00
Owen Taylor
bedbbabba7 Handle the end of the string properly when max_len is set. (#88545, Morten
Thu Jul 25 19:52:41 2002  Owen Taylor  <otaylor@redhat.com>

        * glib/guniprop.c (real_tolower): Handle the
        end of the string properly when max_len is set.
        (#88545, Morten Welinder.) Rename the next_t
        variable to next_type to make cc-mode happy.

        * glib/gconvert.c (g_iconv_open): Fix missing
        label from previous commit.
2002-07-25 23:58:00 +00:00
Owen Taylor
5bfdd206c1 hu Jul 25 19:41:03 2002 Owen Taylor <otaylor@redhat.com>
* glib/giochannel.c (g_io_channel_get_flags): Fix
        incorrect return value in g_return_val_if_fail
        (#85545, David L. Cooper II)
2002-07-25 23:42:25 +00:00
Owen Taylor
46d1844845 Clarify that only one of the conditions listed in the docs need to be
Thu Jul 25 19:12:43 2002  Owen Taylor  <otaylor@redhat.com>

        * glib/giochannel.c (g_io_channel_set_encoding): Clarify
        that only one of the conditions listed in the docs
        need to be true, not all of them. (#87176,
        Sebastian Rittau)

        * glib/giochannel.c (g_io_channel_read_line): Fix
        description of the return value. (#87754, Manuel Clos)
2002-07-25 23:15:41 +00:00
Owen Taylor
1d3b965d07 Remove reference in the docs to @notify parameter. (#87768, Manuel Clos)
Thu Jul 25 19:02:53 2002  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c (g_timeout_add): Remove reference
        in the docs to @notify parameter. (#87768,
        Manuel Clos)
2002-07-25 23:04:22 +00:00
Owen Taylor
2658448f76 Document the (GIConv)-1 return value on failure. (#87559, Jarek Dukat)
Thu Jul 25 17:57:07 2002  Owen Taylor  <otaylor@redhat.com>

        * glib/gconvert.c (g_iconv_open): Document the
        (GIConv)-1 return value on failure. (#87559,
        Jarek Dukat)

        * glib/gconvert.c (g_iconv_open): Fix potential
        problems with the assumption that (GIConv)(iconv_t)-1
        is the same as (GIConv)-1.
2002-07-25 22:35:17 +00:00
Matthias Clasen
0a064bd795 New function to get the currently open element. (#70448)
* glib/gmarkup.h:
	* glib/gmarkup.c (g_markup_parse_context_get_element): New
	function to get the currently open element.  (#70448)
2002-07-15 21:33:18 +00:00
Sebastian Wilhelmi
d81ac5339f Added #undef G_DISABLE_ASSERT and #undef G_LOG_DOMAIN throughout the
2002-07-04  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* tests/*.c: Added #undef G_DISABLE_ASSERT and #undef G_LOG_DOMAIN
	throughout the files, which didn't already have them. (#87312)
2002-07-04 15:19:30 +00:00
Sebastian Wilhelmi
852ed69e87 Made the thread flags determination tests first check for the canonical
2002-07-03  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

        * configure.in: Made the thread flags determination tests first
	check for the canonical form -pthread[s], then for other
	possibilities. Also recognize some more platforms. Modeled after
	patch from Miroslaw Dobrzanski-Neumann <mne@mosaic-ag.com>
	(#77981).
2002-07-03 16:43:22 +00:00
Sebastian Wilhelmi
8f167cbecd Fixed bugs in posix thread priority resolution. Also added AIX priorities.
2002-07-03  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* configure.in: Fixed bugs in posix thread priority
	resolution. Also added AIX priorities. Fix from
	Laurent Vivier <Laurent.Vivier@bull.net>. (#82599)
2002-07-03 15:30:46 +00:00
Sebastian Wilhelmi
5f38e99895 Use thr_min_stack() instead of sysconf (_SC_THREAD_STACK_MIN). if
2002-07-03  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* gthread/gthread-solaris.c: Use thr_min_stack() instead of
	sysconf (_SC_THREAD_STACK_MIN). if stack_size is 0 on entry to
	g_thread_create_solaris_impl, also pass 0 to thr_create. Otherwise
	the stack might be to small for any nontrivial thread. Discovered
	on intel-solaris by Rajkumar Sivasamy <rajkumar.siva@wipro.com>.
2002-07-03 10:38:49 +00:00
Anders Carlsson
07f352af63 Add a forgotten trailing ` in the GLIB_BINARY_AGE expression. Also fixup
2002-07-03  Anders Carlsson  <andersca@gnu.org>

	* configure.in: Add a forgotten trailing ` in the
	GLIB_BINARY_AGE expression. Also fixup LT_CURRENT.
2002-07-03 08:14:42 +00:00
Sebastian Wilhelmi
47791a0ed8 Improve checks for dce/posix threads to also do the right thing, if the
2002-07-02  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* configure.in: Improve checks for dce/posix threads to also do
	the right thing, if the thread functions are not declared in the
	pthread.h. Idea from Miroslaw Dobrzanski-Neumann
	<mne@mosaic-ag.com> in #77981.
2002-07-02 12:41:46 +00:00
Sebastian Wilhelmi
b826ae8db4 Set binary age to 0 to make it compile.
2002-07-02  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* configure.in: Set binary age to 0 to make it compile.
2002-07-02 07:18:48 +00:00
Anders Carlsson
ab44c4b616 Up version to 2.1.0.
2002-07-01  Anders Carlsson  <andersca@gnu.org>

	* configure.in: Up version to 2.1.0.
2002-07-01 16:56:25 +00:00
Sebastian Wilhelmi
3fae7d8360 Fixed ChangeLog entry
Fixed ChangeLog entry
2002-07-01 12:42:20 +00:00
Sebastian Wilhelmi
627926a6cf Add parenthesis to protect macro argument. Spotted by Sam Couter"
2002-07-01  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* glib/garray.h: Add parenthesis to protect macro
	argument. Spotted by Sam Couter" <sam@topic.com.au>. (#86826)
2002-07-01 12:41:50 +00:00
Sebastian Wilhelmi
f6ccf00fed In case of G_DISABLE_ASSERT replace "G_STMT_START{ }G_STMT_END" with
2002-06-28  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

	* glib/gmessages.h (g_assert, g_assert_not_reached,
	g_return_if_fail, g_return_val_if_fail): In case of
	G_DISABLE_ASSERT replace "G_STMT_START{ }G_STMT_END" with
	"G_STMT_START{ (void)0; }G_STMT_END", because the former chokes
	gcc prior to 3.0. (#86664)
2002-06-28 08:41:16 +00:00
Yanko Kaneti
a7174adefb Added Bulgarian (bg).
2002-06-26  Yanko Kaneti <yaneti@declera.com>

   * configure.in: (ALL_LINGUAS) Added Bulgarian (bg).

po/

   * bg.po (added): Bulgarian translation by
   Borislav Aleksandrov <B.Aleksandrov@cnsys.bg>.
2002-06-26 08:27:48 +00:00
Owen Taylor
52644b08e7 Make interval unsigned to match g_timeout_source_new(). (#82624, Tim
Thu Jun 13 16:12:04 2002  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c (struct _GTimeoutSource): Make
        interval unsigned to match g_timeout_source_new().
        (#82624, Tim Janik.)

        * glib/gmain.c (g_timeout_prepare): Add some
        extra gymnastics to avoid signed/unisgned integer
        overflows.
2002-06-13 20:14:43 +00:00
Owen Taylor
23b21c2414 Add a note about the deficiency of Tru64 iconv. (#81699, Manuel Op de
Thu Jun 13 15:57:46 2002  Owen Taylor  <otaylor@redhat.com>

	* INSTALL.in: Add a note about the deficiency
	of Tru64 iconv. (#81699, Manuel Op de Coul)
2002-06-13 20:00:58 +00:00
Owen Taylor
89a078ae68 ChangeLog fixes 2002-06-11 23:27:33 +00:00
Owen Taylor
36adc08bfd tests/patterntest.c (test_compilation) A couple of 64-bit printf format
Tue Jun 11 17:03:39 2002  Owen Taylor  <otaylor@redhat.com>

        * tests/patterntest.c (test_compilation)
        * glib/gmem.c (profiler_try_realloc): A couple
        of 64-bit printf format fix from George Lebl.

        * glib/gconvert.c (open_converter): Fix gsize/gint
        mixup for g_iconv() arguments.
2002-06-11 21:04:50 +00:00
Matthias Clasen
a2e3f606ed Replace homegrown "hash" entity by standard ISO entity "num".
* glib/gwin32.c (g_win32_get_package_installation_directory):
	Replace homegrown "hash" entity by standard ISO entity "num".

	* gobject/gobject-docs.sgml:
	* glib/glib-docs.sgml:
	* glib/tmpl/macros.sgml:
	* glib/tmpl/string_utils.sgml: Replace homegrown "nbsp", "hash"
	and "percent" entities by standard ISO entities "nbsp", "num" and
	"percnt".
2002-06-03 17:34:37 +00:00
Matthias Clasen
5e45a337b8 Remove references to nonexisting functions
* glib/gmain.c: Remove references to nonexisting functions
	g_source_set_callback_closure(), g_source_poll(), g_source_add()
	from docs.

	* glib/gdir.c (g_dir_open): Typo fix in docs.

	* glib/gasyncqueue.c (g_async_queue_lock):
	(g_async_queue_unref_and_unlock): Fix markup to avoid erroneous
	<link>s in docs.

	* glib/gwin32.c: Escape #'s leading to erroneous <link>s in docs.

	* glib/gtree.c: Replace some occurances of Gtree by GTree in docs.

	* glib/gstring.c (g_string_insert_unichar): Typo fix in docs.

	* glib/tmpl/conversions.sgml: Add GIConv.

	* glib/tmpl/main.sgml: Fix references to nonexisting functions
	g_main_loop_destroy(), g_source_add(), g_source_connect().

	* glib/glib-sections.txt: Add GIConv, g_str_has_prefix, g_str_has_suffix.

	* glib/tmpl/linked_lists_single.sgml:
	* glib/tmpl/linked_lists_double.sgml: GListAllocator doesn't exist.

	* glib/glib-docs.sgml: Declare hash entity.

	* glib/tmpl/macros.sgml: Escape # in #ifdef to suppress erroneous links.

	* gobject/Makefile.am, gobject/gobject-docs.sgml, gobject/tmpl/*:
	* glib/Makefile.am, glib/glib-docs.sgml, glib/tmpl/*: Produce XML,
	not SGML.
2002-05-26 22:46:28 +00:00
Havoc Pennington
1ce72b0584 on success, close the pipes from the child. Fix from Tim.
2002-05-23  Havoc Pennington  <hp@redhat.com>

	* glib/gspawn.c (fork_exec_with_pipes): on success, close the
	pipes from the child. Fix from Tim.
2002-05-23 15:36:53 +00:00