Commit Graph

2949 Commits

Author SHA1 Message Date
Mathias Hasselmann
bef69cd7b3 Resolve 64 bit-shift bug in g_markup_collect_attributes.
Spotted by Lieven van der Heide.

* glib/gmarkup.c: Use G_GUINT64_CONSTANT in bit-shift.

svn path=/trunk/; revision=6243
2008-01-04 12:40:03 +00:00
Alvaro Lopez Ortega
f06829352b These void functions were trying to return a value. It was causing the
2008-01-02  Alvaro Lopez Ortega  <alvaro@sun.com>

        * gio/gunixmount.c (g_unix_mount_unmount, g_unix_mount_eject):
        These void functions were trying to return a value. It was causing
        the compilation to fail.


svn path=/trunk/; revision=6232
2008-01-02 16:22:25 +00:00
Alvaro Lopez Ortega
ed670989f4 These functions prototype defines its output as void, and therefore they
2008-01-02  Alvaro Lopez Ortega  <alvaro@sun.com>

       * glib/ghash.c (g_hash_table_replace, g_hash_table_insert): These
       functions prototype defines its output as void, and therefore they
       should not return any value. This patch fixes a compilation error:
       the "return" clauses were incompatible with the functions prototype.

svn path=/trunk/; revision=6230
2008-01-02 11:54:08 +00:00
Matthias Clasen
9a1cf274de Remove C99 comments
svn path=/trunk/; revision=6227
2008-01-01 04:13:26 +00:00
Matthias Clasen
de08b57f02 Mark assertion functions as G_GNUC_NORETURN. (#506461, Sebastian Dröge)
2007-12-24  Matthias Clasen  <mclasen@redhat.com>

        * glib/gtestutils.h:
        * glib/glib.symbols: Mark assertion functions as G_GNUC_NORETURN.
        (#506461, Sebastian Dröge)



svn path=/trunk/; revision=6221
2007-12-31 05:25:25 +00:00
Matthias Clasen
b7a377a486 Include sys/time.h. (#505258)
2007-12-24  Matthias Clasen  <mclasen@redhat.com>

        * glib/gtestutils.c: Include sys/time.h.  (#505258)



svn path=/trunk/; revision=6201
2007-12-25 02:28:18 +00:00
Mathias Hasselmann
cce26f9ee5 Use correct date of in ChangeLog entry (once again)
svn path=/trunk/; revision=6199
2007-12-24 11:10:13 +00:00
Mathias Hasselmann
005a22ab10 Do not show empty groups in --help output. Initial patch from Yevgen
Muntyan. (#504142)

* glib/goption.c: Do not show empty groups in --help output.
* glib/tests/Makefile.am: Add option-context.c
* glib/tests/option-context.c: Test skipping of empty groups.

svn path=/trunk/; revision=6198
2007-12-24 11:09:03 +00:00
Matthias Clasen
2a7f1a1a9c Remove wrong documentation about start group handling. (#476856, Areg
2007-12-22  Matthias Clasen  <mclasen@redhat.com>

        * glib/gkeyfile.c: Remove wrong documentation about start group
        handling.  (#476856, Areg Beketovski)



svn path=/trunk/; revision=6190
2007-12-23 04:57:23 +00:00
18:02:30 Tim Janik
0a76f7d6b4 use "sed -i.bak <CMD> <FILE> && rm -f <FILE>.bak" syntax for
2007-12-21 18:02:30  Tim Janik  <timj@imendio.com>

        * glib/Makefile.am: use "sed -i.bak <CMD> <FILE> && rm -f <FILE>.bak"
        syntax for install-exec-hook, which seems to be the only "sed -i"
        variant that is portable across linux and MacOS.



svn path=/trunk/; revision=6187
2007-12-21 17:02:29 +00:00
Matthias Clasen
c53134b57c Bring up to GLib coding standards: remove C99 comments, trailing commas in
2007-12-21  Matthias Clasen  <mclasne@redhat.com>

        * glib/gtestutils.h: Bring up to GLib coding standards: remove
        C99 comments, trailing commas in enumerations and extra ; after
        G_BEGIN/END_DECLS. Among other things, this makes xulrunner build
        against GLib 2.15.

        * glib/gtester.c: More of the same


svn path=/trunk/; revision=6185
2007-12-21 13:58:42 +00:00
Hans Breuer
1cda3c9e01 adapt to recent api changes variable declaration at the beginning of a
2007-12-09  Hans Breuer  <hans@breuer.org>

	* tests/gio-ls.c : adapt to recent api changes
	* tests/testglib.c : variable declaration at the beginning of a block
	
	(Lieven van der Heide, #503602)
	* win32-fixup.pl : process *.rc.in as well; substitute 
	LT_CURRENT_MINUS_AGE
	* glib/makefile.msc.in : alphabetic sorting of OBJECTS


svn path=/trunk/; revision=6184
2007-12-21 10:11:35 +00:00
Matthias Clasen
41358ed237 Bump version
svn path=/trunk/; revision=6182
2007-12-21 00:44:40 +00:00
Matthias Clasen
48ba9ea756 2.15.0
svn path=/trunk/; revision=6180
2007-12-21 00:37:41 +00:00
Matthias Clasen
56bee25225 Updates
svn path=/trunk/; revision=6179
2007-12-20 20:24:20 +00:00
Matthias Clasen
0c99959a79 Fix make dist
svn path=/trunk/; revision=6177
2007-12-20 15:50:08 +00:00
16:34:04 Tim Janik
798aaac34f commented class definitions. moved HTML character escaping out of
2007-12-20 16:34:04  Tim Janik  <timj@imendio.com>

        * glib/gtester-report: commented class definitions. moved HTML character
        escaping out of javascript. fixed string->bool conversions. added performance
        results to test case "Details" window.



svn path=/trunk/; revision=6176
2007-12-20 15:35:21 +00:00
Matthias Clasen
877cc60f03 Return NULL if the checksum_type is unknown
svn path=/trunk/; revision=6175
2007-12-20 15:12:40 +00:00
Christian Persch
fc23e6ffac Use g_slice_new0, to fix "conditional jump or move depends on
2007-12-20  Christian Persch  <chpe@gnome.org>

	* glib/gchecksum.c: (g_checksum_new): Use g_slice_new0, to fix
	"conditional jump or move depends on uninitialised value(s)" error
	from valgrind. Bug #504527.

svn path=/trunk/; revision=6174
2007-12-20 14:20:31 +00:00
15:17:04 Tim Janik
d08fd8eae2 generate HTML reports for test-report perf-report full-report.
2007-12-20 15:17:04  Tim Janik  <timj@imendio.com>

        * Makefile.decl: generate HTML reports for test-report perf-report full-report.



svn path=/trunk/; revision=6172
2007-12-20 14:14:50 +00:00
15:03:51 Tim Janik
8acddd1ab4 new python script that generates an HTML unit test report from the XML
2007-12-20 15:03:51  Tim Janik  <timj@imendio.com>

        * glib/gtester-report: new python script that generates an HTML
        unit test report from the XML files generated by gtester.

        * glib/Makefile.am: install gtester-report in $bindir and configure
        it upon installation (version number and python shebang).



svn path=/trunk/; revision=6171
2007-12-20 14:01:26 +00:00
Matthias Clasen
aa07a74b41 Additions
svn path=/trunk/; revision=6164
2007-12-20 02:56:03 +00:00
20:30:18 Tim Janik
aeeb80baf6 capture g_log() messages and send to gtester. also, send assertion
2007-12-19 20:30:18  Tim Janik  <timj@imendio.com>

        * glib/gtestutils.c: capture g_log() messages and send to gtester.
        also, send assertion messages to gtester.

        * glib/gtester.c: add error messages to output log file.
        force child poll loop to abort if waitpid() signaled child exit,
        eventhough the child's report file descriptor wasn't closed.



svn path=/trunk/; revision=6163
2007-12-19 19:28:55 +00:00
Christian Persch
1ea515d019 Add g_checksum_type_get_length, and change g_checksum_get_digest to use a
2007-12-19  Christian Persch  <chpe@gnome.org>

	* glib/gchecksum.c: (g_checksum_type_get_length),
	(g_checksum_get_digest):
	* glib/gchecksum.h:
	* glib/glib.symbols:
	* tests/checksum-test.c: (test_checksum): Add
	g_checksum_type_get_length, and change g_checksum_get_digest to use a
	provided buffer instead of returning allocated memory. Bug #501853.

svn path=/trunk/; revision=6162
2007-12-19 18:53:27 +00:00
Emmanuele Bassi
a979c0d5a2 Fix the date validation check. (#503029)
2007-12-19  Emmanuele Bassi  <ebassi@gnome.org>

	* glib/gtimer.c (g_time_val_from_iso8601): Fix the date validation
	check. (#503029)

	* tests/testglib.c (various_string_tests): Add an invalid date
	for testing the above fix.

svn path=/trunk/; revision=6160
2007-12-19 17:28:38 +00:00
Alexander Larsson
de9c37dd91 Rename g_format_file_size_for_display to g_format_size_for_display.
2007-12-19  Alexander Larsson  <alexl@redhat.com>

        * glib/gfileutils.[ch]:
        * glib/glib.symbols:
        Rename g_format_file_size_for_display to g_format_size_for_display.



svn path=/trunk/; revision=6158
2007-12-19 13:25:09 +00:00
Tim-Philipp Müller
3ca41fe109 add g_async_queue_new_full() which takes a GDestroyNotify function to free
* docs/reference/glib/glib-sections.txt:
	* glib/gasyncqueue.c: (g_async_queue_new), (g_async_queue_new_full),
	  (g_async_queue_unref):
	* glib/gasyncqueue.h: add g_async_queue_new_full() which takes a
	  GDestroyNotify function to free any remaining queue items when the
	  queue is destroyed after the final atomic unref (#367550).


svn path=/trunk/; revision=6152
2007-12-18 16:46:36 +00:00
13:45:23 Tim Janik
ac1723ea97 added g_test_trap_assert_stdout_unmatched() and
2007-12-18 13:45:23  Tim Janik  <timj@imendio.com>

        * glib/gtestutils.[hc]: added g_test_trap_assert_stdout_unmatched() and
        g_test_trap_assert_stderr_unmatched(), based on a suggestion by Mathias
        Hasselmann. reworked g_test_trap_assertions() to use flags to encode
        assertion semantics, fixes #504227.



svn path=/trunk/; revision=6151
2007-12-18 13:43:46 +00:00
Mathias Hasselmann
f87b822b21 Allow NULL strings in g_parse_debug_string. (#503862, Matthew Barnes)
* glib/gutils.c:
Allow NULL strings in g_parse_debug_string. (#503862, Matthew Barnes)

svn path=/trunk/; revision=6137
2007-12-16 15:04:51 +00:00
Matthias Clasen
d741d3e7a3 Add hash table iterators. (#500507, Jean-Yves Lefort)
2007-12-14  Matthias Clasen  <mclasen@redhat.com>

        * glib/glib.symbols:
        * glib/ghash.[hc]: Add hash table iterators.  (#500507,
        Jean-Yves Lefort)

        * tests/hash-test.c: Test iterators.



svn path=/trunk/; revision=6130
2007-12-15 03:54:09 +00:00
Yevgen Muntyan
887e45888d Moved the ChangeLog entry to gio/ChangeLog
svn path=/trunk/; revision=6127
2007-12-14 14:34:11 +00:00
Yevgen Muntyan
ee5aacbc61 Fixed build when srcdir != builddir, made mkenums and friends use
2007-12-14  Yevgen Muntyan  <muntyan@tamu.edu>

	* gio/Makefile.am:
	* gio/inotify/Makefile.am: Fixed build when srcdir != builddir,
	made mkenums and friends use temporary files to avoid leaving
	empty generated files on failure (#503470).


svn path=/trunk/; revision=6126
2007-12-14 14:28:35 +00:00
Mathias Hasselmann
69f071c88b Give exmples in error message unsupported case-changing escape
sequences. (503222)

* glib/gregex.c: Add examples to error message for PCRE-ERR37.

svn path=/trunk/; revision=6113
2007-12-13 15:08:59 +00:00
Bastien Nocera
7bebca1f2e Don't try to parse dates that start with anything but a digit, a plus or a
2007-12-13  Bastien Nocera  <hadess@hadess.net>

	* glib/gtimer.c: (g_time_val_from_iso8601):
	Don't try to parse dates that start with anything but a
	digit, a plus or a minus sign, as those can't be valid
	ISO8601 dates (Closes: #503029)


svn path=/trunk/; revision=6111
2007-12-13 14:44:37 +00:00
Matthias Clasen
20d002d466 Free group_hash. (#503420, Christian Persch)
2007-12-13  Matthias Clasen  <mclasen@redhat.com>

        * glib/gkeyfile.c (g_key_file_clear): Free group_hash.
        (#503420, Christian Persch)


svn path=/trunk/; revision=6107
2007-12-13 13:56:08 +00:00
16:06:11 Tim Janik
0efd85aeac split up tests and reworked code to use the new test framework.
2007-12-12 16:06:11  Tim Janik  <timj@imendio.com>

        * tests/testglib.c: split up tests and reworked code to use
        the new test framework.

        * tests/Makefile.am: added testglib to TEST_PROGS.



svn path=/trunk/; revision=6103
2007-12-12 15:09:08 +00:00
Mathias Hasselmann
2de9f839a0 Use proper ChangeLog file for the rev 6098 change.
svn path=/trunk/; revision=6099
2007-12-12 10:36:08 +00:00
Mathias Hasselmann
a5427003d3 Always exit with non-zero error code when printing warnings.
* gobject/glib-genmarshal.c: Add global exit_status variable, and use
it in pad() and process_signature() to return with non-zero error code
when printing warnings. (#495294)

svn path=/trunk/; revision=6098
2007-12-12 10:19:43 +00:00
Rahul Bhalerao
c2643afd24 Added Marathi Translations
svn path=/trunk/; revision=6094
2007-12-11 12:37:30 +00:00
Matthias Clasen
40ec4f95ff Include gurifuncs.h
2007-12-10  Matthias Clasen  <mclasen@redhat.com>

        * glib/glib.h: Include gurifuncs.h



svn path=/trunk/; revision=6093
2007-12-11 01:48:23 +00:00
Benjamin Otte
c17aa5bc42 use an intermediate cast to void * in g_array_index() to not trigger cast
* glib/garray.h: use an intermediate cast to void * in g_array_index() 
to not trigger cast alignment warnings, fixes #502927.

svn path=/trunk/; revision=6092
2007-12-10 22:27:40 +00:00
15:08:59 Tim Janik
cc3de68e21 http://mail.gnome.org/archives/gtk-devel-list/2007-October/msg00089.html
2007-12-10 15:08:59  Tim Janik  <timj@imendio.com>

        * let g_warn_if_fail replace g_assert as discussed here:
          http://mail.gnome.org/archives/gtk-devel-list/2007-October/msg00089.html

        * fix bug #502498: Test framework assertion failures should follow
        gcc error format.

        * gmessages.h, gmessages.c: deprecated g_assert_warning() which is
        unused now. removed g_assert*() definitions whcih are provided by 
        gtestutils.h now. added g_warn_if_reached() and g_warn_if_fail()  
        which are recommended as g_assert/g_assert_not_reached replacements
        for non-test programs.
        added g_warn_message() to implement g_warn_*() macros.
        use emacs-next-error friendly formatting for file:line: for warnings.

        * gtestutils.h, gtestutils.c: use emacs-next-error friendly formatting.
        implement g_assert_not_reached() with g_assertion_message() and
        g_assert() in terms of g_assertion_message_expr() so we'll be able to
        provide assertion messages in test logs.

        * gkeyfile.c, gbookmarkfile.c: changed g_assert*() to g_warn_if_fail()
        or g_return_if_fail() where suitable.

        * gio/: changed g_assert to g_warn_if_fail.



svn path=/trunk/; revision=6086
2007-12-10 14:07:42 +00:00
13:02:08 Tim Janik
0dbfa89ba1 applied patch by Tommi Komulainen to fix int64 printouts, fixes #502511.
2007-12-10 13:02:08  Tim Janik  <timj@imendio.com>

        * glib/gtestutils.c (g_assertion_message_cmpnum): applied patch by Tommi
        Komulainen to fix int64 printouts, fixes #502511.



svn path=/trunk/; revision=6085
2007-12-10 12:02:48 +00:00
Matthias Clasen
d0d19f0dba Change prototype to take msgctxtid + offset instead of two strings, to
2007-12-10  Matthias Clasen  <mclasen@redhat.com>

        * glib/gstrfuncs.h:
        * glib/gstrfuncs.c (g_dpgettext): Change prototype to take
        msgctxtid + offset instead of two strings, to avoid duplication
        of string constants if the compiler/linker don't perform constant
        suffix merging.  (#502590, Christian Persch)

        * glib/gi18n.h:
        * glib/gi18n-lib.h: Adapt the definitions of C_() and Q_().


svn path=/trunk/; revision=6081
2007-12-10 05:24:36 +00:00
Hans Breuer
29ca2e26b0 a test program emulating some of 'ls' build it (currently on win32)
2007-12-09  Hans Breuer  <hans@breuer.org>

	* tests/gio-ls.c : (new file) a test program emulating some of 'ls'
	* tests/makefile.msc.in : build it (currently on win32)


svn path=/trunk/; revision=6079
2007-12-09 22:02:15 +00:00
Hans Breuer
b877c83cdc removed -GD to compile with msvc9 (vs2008) with less complains
2007-12-09  Hans Breuer  <hans@breuer.org>

	* **/makefile.msc glib/makefile.msc.in : removed -GD to compile
	with msvc9 (vs2008) with less complains
	
	* glibconfig.h.win32.in : #define G_HAVE_ISO_VARARGS 1 for
	msv8 (vs2005) and above
	
	* glib/gfileutils.c : s/stricmp/_stricmp/
	* msvc_recommended_pragmas.h : work around Microsoft's premature 
	attempt to deprecate the C-Library

	* tests/makefile.msc.in : added checksum-test


svn path=/trunk/; revision=6076
2007-12-09 14:38:26 +00:00
Christian Persch
3c3d3e25ff Add forgotten #ifdef G_OS_WIN32 to fix the build on linux.
2007-12-08  Christian Persch  <chpe@gnome.org>

	* gio/glocalfileinfo.c: (get_thumbnail_attributes): Add forgotten
	#ifdef G_OS_WIN32 to fix the build on linux.

svn path=/trunk/; revision=6074
2007-12-08 14:29:37 +00:00
Hans Breuer
1ac4ff6c10 build gchecksum.obj
2007-12-08  Hans Breuer  <hans@breuer.org>

	* glib/makefile.msc.in : build gchecksum.obj


svn path=/trunk/; revision=6071
2007-12-08 12:02:22 +00:00
Mathias Hasselmann
bb10169eb4 Call destroy notify when destroying the hash table in g_hash_table_unref.
* glib/ghash.c: Call destroy notify when destroying the hash table in
g_hash_table_unref.

svn path=/trunk/; revision=6060
2007-12-06 15:38:03 +00:00
13:29:00 Tim Janik
8844df9101 detect non-blocking fd EOF by read()==0 following poll(), needed on MacOS.
2007-12-06 13:29:00  Tim Janik  <timj@imendio.com>

        * glib/gtester.c (child_report_cb): detect non-blocking fd EOF
        by read()==0 following poll(), needed on MacOS.



svn path=/trunk/; revision=6059
2007-12-06 12:28:25 +00:00
Mathias Hasselmann
c79ef3793c Mention g_utf8_normalize() returns NULL on invalid string. (#501997)
* glib/gunidecomp.c: Mention g_utf8_normalize()
returns NULL on invalid string. (#501997)

svn path=/trunk/; revision=6058
2007-12-06 10:22:13 +00:00
Mathias Hasselmann
a27d6affec Improve wording for g_propagate_error docs.
* glib/gerror.c: Improve wording for g_propagate_error docs.

svn path=/trunk/; revision=6056
2007-12-06 09:20:13 +00:00
09:27:42 Tim Janik
871897db96 added new scanner test from #501654, by Patrick Hulin with various
2007-12-06 09:27:42  Tim Janik  <timj@imendio.com>

        * tests/scannerapi.c: added new scanner test from #501654, by
        Patrick Hulin with various modifications.
        reworked coding style, adapted to new testing framework, fixed
        token parser test and use a forked sub process to test
        g_scanner_error() output messages.



svn path=/trunk/; revision=6055
2007-12-06 08:32:03 +00:00
17:58:18 Tim Janik
ae2157fa45 added -m=thorough support to gtester.
2007-12-05 17:58:18  Tim Janik  <timj@imendio.com>

        * glib/gtester.c: added -m=thorough support to gtester.



svn path=/trunk/; revision=6053
2007-12-05 16:56:05 +00:00
17:21:05 Tim Janik
d4bfa601f7 print out random seed for verbose tests, also adapted test result
2007-12-05 17:21:05  Tim Janik  <timj@imendio.com>

        * glib/glib/gtestutils.c: print out random seed for verbose tests,
        also adapted test result reporting slightly in verbose mode to allow
        custom debugging output. support "thorough" as test mode alis for "slow".

        * glib/glib/gtestutils.h: added g_test_thorough().

        * glib/glib/gtester.c: print out the last random seed when tests fail.
        added result attribute to test case status logging to easily spot
        failing tests in log files. disabled debugging output when skipping tests.



svn path=/trunk/; revision=6052
2007-12-05 16:22:44 +00:00
11:43:22 Tim Janik
510d4ec634 added g_test_add_data_func() to pass data into tests. allow data arguments
2007-12-05 11:43:22  Tim Janik  <timj@imendio.com>

        * glib/gtestutils.[hc]: added g_test_add_data_func() to pass data
        into tests. allow data arguments for fixture tests.

        * glib/gtestutils.c: fixed fatal log flag setup, so tests really abort
        upon criticals/warnings/errors.

        * glib/tests/testing.c: test test_data arguments.

        * glib/gtester.c: some prototype fixups.



svn path=/trunk/; revision=6049
2007-12-05 10:42:09 +00:00
Tor Lillqvist
a8a42c8b15 Add "shift-jis" as an alternative spelling of "shift_jis".
2007-12-05  Tor Lillqvist  <tml@novell.com>

	* glib/win_iconv.c: Add "shift-jis" as an alternative spelling of
	"shift_jis".


svn path=/trunk/; revision=6047
2007-12-05 07:14:19 +00:00
Ryan Lortie
330c7a6851 for the benefit of git users, checkout build/ if it is missing but after
2007-12-05  Ryan Lortie  <desrt@desrt.ca>

        * autogen.sh: for the benefit of git users, checkout build/ if it is
        missing
        * .gitignore: but after that, ignore it.


svn path=/trunk/; revision=6046
2007-12-05 06:34:18 +00:00
Ryan Lortie
4c78fb8faa ungtk-docify some comments for internal functions
2007-12-05  Ryan Lortie  <desrt@desrt.ca>

        * glib/ghash.c: ungtk-docify some comments for internal functions


svn path=/trunk/; revision=6045
2007-12-05 06:09:55 +00:00
Emmanuele Bassi
d013d46b98 Replace the copy-and-paste MD5 digest generation with GChecksum.
2007-12-04  Emmanuele Bassi  <ebassi@gnome.org>

	* gio/glocalfileinfo.c: Replace the copy-and-paste MD5 digest
	generation with GChecksum.

svn path=/trunk/; revision=6043
2007-12-04 16:33:24 +00:00
Emmanuele Bassi
f17db34652 Add GChecksum, a generic wrapper around various hashing algorithms. At the
2007-12-04  Emmanuele Bassi  <ebassi@gnome.org>

	* glib/gchecksum.[ch]: Add GChecksum, a generic wrapper around
	various hashing algorithms. At the moment, the MD5, SHA-1 and
	SHA-256 algorithms are supported. (#443648)

	* glib/glib.h:
	* glib/Makefile.am:
	* glib/glib.symbols: Build glue for GChecksum

	* tests/Makefile.am
	* tests/checksum-test.c: Add test suite for GChecksum.

svn path=/trunk/; revision=6042
2007-12-04 16:31:51 +00:00
Ryan Lortie
0b89fa790a no code changes; add comments to document the internal functions.
2007-12-03  Ryan Lortie  <desrt@desrt.ca>

        * glib/ghash.c: no code changes; add comments to document the internal
        functions.


svn path=/trunk/; revision=6037
2007-12-04 03:47:17 +00:00
Ryan Lortie
ac44f9cb5a no code changes; reorder functions to remove the need for forward
2007-12-03  Ryan Lortie  <desrt@desrt.ca>

        * glib/ghash.c: no code changes; reorder functions to remove the need
        for forward declarations.


svn path=/trunk/; revision=6036
2007-12-04 03:47:03 +00:00
Ryan Lortie
d72c02686b improve clarity in some functions
2007-12-03  Ryan Lortie  <desrt@desrt.ca>

        * glib/ghash.c (g_hash_table_lookup_node,
        g_hash_table_lookup_extended, g_hash_table_insert_internal,
        g_hash_node_new): improve clarity in some functions


svn path=/trunk/; revision=6035
2007-12-04 03:46:48 +00:00
Ryan Lortie
8a38e16052 rename 'node' to 'node_ptr' where appropriate
2007-12-03  Ryan Lortie  <desrt@desrt.ca>

        * glib/ghash.c: rename 'node' to 'node_ptr' where appropriate


svn path=/trunk/; revision=6034
2007-12-04 03:46:31 +00:00
Ryan Lortie
00c2db4e4b convert G_HASH_TABLE_RESIZE() macro to inline function
2007-12-03  Ryan Lortie  <desrt@desrt.ca>

        * glib/ghash.c: convert G_HASH_TABLE_RESIZE() macro to inline function


svn path=/trunk/; revision=6033
2007-12-04 03:46:13 +00:00
Ryan Lortie
591e89c589 remove stray (duplicate) entry from file to fix the build
2007-12-03  Ryan Lortie  <desrt@desrt.ca>

	* glib/glib.symbols (glib_gettext): remove stray (duplicate) entry
	from file to fix the build



svn path=/trunk/; revision=6031
2007-12-04 01:26:46 +00:00
Behdad Esfahbod
a38a770636 Fix EXTRA_DIST automake warnings. (#501107)
2007-12-03  Behdad Esfahbod  <behdad@gnome.org>

        * glib/gnulib/Makefile.am: Fix EXTRA_DIST automake warnings. (#501107)


svn path=/trunk/; revision=6029
2007-12-04 00:35:42 +00:00
Hans Breuer
27cb515443 added glib_gettext (in use by gio) also try building gio
2007-12-03  Hans Breuer  <hans@breuer.org>

	* glib/glib.symbols : added glib_gettext (in use by gio)
	* makefile.msc : also try building gio
	
	* glib/gmarkup.c : use G_GUINT64_CONSTANT() to avoid 
	'bad suffix on number'
	* glib/gtestutils.c : declare cariable at the beginning of the block,
	include <io.h> for G_OS_WIN32
	* makefile.msc.in : add gurifuncs and gtestutils


svn path=/trunk/; revision=6028
2007-12-03 22:46:17 +00:00
Ryan Lortie
72ed8191af create a common function for the many places where all nodes in the table
2007-12-03  Ryan Lortie  <desrt@desrt.ca>

	* glib/ghash.c: create a common function for the many places where all
	nodes in the table are removed (remove_all, steal_all, destroy, unref,
	etc...)



svn path=/trunk/; revision=6026
2007-12-03 21:21:28 +00:00
Ryan Lortie
18fc4b8f02 fix memory leak, add a few extra sanity tests.
2006-12-03  Ryan Lortie  <desrt@desrt.ca>

	* tests/hash-test.c (second_hash_test): fix memory leak, add a few
	extra sanity tests.



svn path=/trunk/; revision=6025
2007-12-03 21:17:32 +00:00
Matthias Clasen
2efc55c68e Don't call g_get_language_names() per-key. (#500638, Michael Meeks)
2007-12-03  Matthias Clasen  <mclasen@redhat.com>

        * glib/gkeyfile.c: Don't call g_get_language_names() per-key.
        (#500638, Michael Meeks)


svn path=/trunk/; revision=6023
2007-12-03 18:56:33 +00:00
Marco Barisione
458f3eca76 Add new error codes for when compilation fails and make compilation error
2007-12-03  Marco Barisione <marco@barisione.org>

	* glib/gregex.c:
	* glib/gregex.h: Add new error codes for when compilation fails and
	make compilation error translatable. (#482313, Morten Welinder)

svn path=/trunk/; revision=6021
2007-12-03 18:36:26 +00:00
Matthias Clasen
8e2e557633 Speed up group lookups
svn path=/trunk/; revision=6018
2007-12-03 15:43:20 +00:00
Alexander Larsson
7561ec5765 Add xattr checks for OSX style API (#500506) 2007-12-03 Alexander Larsson
2007-12-03  Alexander Larsson  <alexl@redhat.com>

        * configure.in:
	Add xattr checks for OSX style API (#500506)
2007-12-03  Alexander Larsson  <alexl@redhat.com>

        * glocalfileinfo.c:
	Handle OSX style xattrs API (#500506)



svn path=/trunk/; revision=6017
2007-12-03 10:23:03 +00:00
Ryan Lortie
e9010a86f7 merge more common code into functions. Vastly simplify loop logic in
2007-12-03  Ryan Lortie  <desrt@desrt.ca>

        * glib/ghash.c: merge more common code into functions.  Vastly
        simplify loop logic in g_hash_table_foreach_remove_or_steal().


svn path=/trunk/; revision=6016
2007-12-03 09:29:47 +00:00
Behdad Esfahbod
942f84e6c9 Don't descend into build/. (#500875)
2007-12-01  Behdad Esfahbod  <behdad@gnome.org>

        * Makefile.am: Don't descend into build/. (#500875)


svn path=/trunk/; revision=6012
2007-12-01 23:46:17 +00:00
Matthias Clasen
cf0b542ab0 Doc improvements
svn path=/trunk/; revision=5988
2007-11-29 02:58:24 +00:00
Matthias Clasen
3feb9d4741 Add Since tags
svn path=/trunk/; revision=5986
2007-11-29 02:36:12 +00:00
Matthias Clasen
a2d8858322 Some doc cleanups
svn path=/trunk/; revision=5985
2007-11-29 01:24:33 +00:00
Tor Lillqvist
3deb5aceda Update to match what configure produces.
2007-11-28  Tor Lillqvist  <tml@novell.com>

	* config.h.win32.in: Update to match what configure produces.


svn path=/trunk/; revision=5976
2007-11-28 16:01:16 +00:00
Alexander Larsson
14b59e3847 Move this function before g_string_append_c so that we avoid the plt call
2007-11-28  Alexander Larsson  <alexl@redhat.com>

	* glib/gstring.c (g_string_append_uri_escaped):
	Move this function before g_string_append_c so that
	we avoid the plt call due to the undefinf of g_string_append_c


svn path=/trunk/; revision=5975
2007-11-28 14:49:22 +00:00
Emmanuele Bassi
6ce14033c7 Remove makegioalias.pl from the marshal files and avoid it being cleaned
2007-11-28  Emmanuele Bassi  <ebassi@gnome.org>

	* gio/Makefile.am: Remove makegioalias.pl from the marshal files
	and avoid it being cleaned up when running make clean.

svn path=/trunk/; revision=5974
2007-11-28 14:42:29 +00:00
Alexander Larsson
6ae887bb9b Add in the new symbols
2007-11-28  Alexander Larsson  <alexl@redhat.com>

        * glib/glib.symbols:
	Add in the new symbols
	
        * glib/gurifuncs.c:
	Use the aliases framework
	
        * glib/glibintl.h:
        * glib/gutils.c:
	Make the alias stuff work now that glib_gettext
	is exported to libgio. 


svn path=/trunk/; revision=5973
2007-11-28 14:35:14 +00:00
Ryan Lortie
0adbacbff9 insert/replace were identical except for a single line. Replace both with
2007-11-27  Ryan Lortie  <desrt@desrt.ca>

        * glib/ghash.c (g_hash_table_insert, g_hash_table_replace,
        g_hash_table_insert_internal): insert/replace were identical except
        for a single line.  Replace both with a common function.


svn path=/trunk/; revision=5964
2007-11-28 03:40:39 +00:00
Alexander Larsson
e3607fcdf3 Moved gurifuncs from gio to glib
2007-11-27  Alexander Larsson  <alexl@redhat.com>

        * gio/Makefile.am:
        * gio/gurifuncs.[ch]:
        * glib/Makefile.am:
        * glib/gstring.[ch]:
        * glib/gurifuncs.[ch]:
	Moved gurifuncs from gio to glib


svn path=/trunk/; revision=5955
2007-11-27 14:57:45 +00:00
Alexander Larsson
68c74ba68f Move g_format_file_size_for_display from gio to glib
2007-11-27  Alexander Larsson  <alexl@redhat.com>

        * gio/gfileinfo.[ch]:
        * glib/gfileutils.[ch]:
        Move g_format_file_size_for_display from gio to glib


svn path=/trunk/; revision=5954
2007-11-27 14:30:31 +00:00
Alexander Larsson
2490a699be Allow configuration of gio-module-dir
2007-11-27  Alexander Larsson  <alexl@redhat.com>

        * configure.in:
	Allow configuration of gio-module-dir
	
        * gio-2.0.pc.in:
	Export giomodules location as giomodule variable

2007-11-27  Alexander Larsson  <alexl@redhat.com>

        * Makefile.am:
        * fam/Makefile.am:
        * inotify/Makefile.am:
	Use the user-specified giomoduledir


svn path=/trunk/; revision=5951
2007-11-27 12:39:14 +00:00
Matthias Clasen
b9743a23dd Add some tests for invalid booleans
2007-11-26  Matthias Clasen  <mclasen@redhat.com>

        * tests/markup-collect.c: Add some tests for invalid booleans



svn path=/trunk/; revision=5949
2007-11-27 02:29:31 +00:00
Ryan Lortie
052bd9da4f Add new function g_markup_collect_attributes (bug #496847).
2007-11-26  Ryan Lortie  <desrt@desrt.ca>
 
        Add new function g_markup_collect_attributes (bug #496847).
 
        * glib/glib.symbols: add g_markup_collect_attributes
 
        * docs/reference/glib/glib-sections.txt:
        * glib/gmarkup.h:
        * glib/gmarkup.c: add g_markup_collect_attributes and new enumerated
        type GMarkupCollectType.  Add new error code
        G_MARKUP_ERROR_MISSING_ATTRIBUTE that is thrown by the attribute
        collector.


svn path=/trunk/; revision=5947
2007-11-27 01:37:33 +00:00
Tor Lillqvist
37f2dc3555 Some improvements, being upstreamed. (must_use_null_useddefaultchar): New
2007-11-27  Tor Lillqvist  <tml@novell.com>

	* glib/win_iconv.c: Some improvements, being upstreamed.
	(must_use_null_useddefaultchar): New function, checks for those
	codepages for which one must pass a NULL lpUsedDefaultChar pointer
	to WideCharToMultiByte().
	(kernel_wctomb): Use it.
	(kernel_wctomb): Return with E2BIG immediately if bufsize is zero.


svn path=/trunk/; revision=5945
2007-11-26 22:49:43 +00:00
Tor Lillqvist
007d3ad28a Use either lib/locale or share/locale depending on which one is in
2007-11-27  Tor Lillqvist  <tml@novell.com>

	* glib/gutils.c (_glib_get_locale_dir) [Win32]: Use either
	lib/locale or share/locale depending on which one is in
	GLIB_LOCALE_DIR. When the configury recognizes GNU gettext (based
	on the _nl_msg_cat_cntr variable, eek), share/locale gets used.

	* glib-zip.in: Likewise, look for message catalogs either in
	lib/locale or share/locale.


svn path=/trunk/; revision=5944
2007-11-26 22:32:12 +00:00
Matthias Clasen
13195ef836 Fix up a doc comment
svn path=/trunk/; revision=5943
2007-11-26 20:42:17 +00:00
Alexander Larsson
3781343738 gio/ docs/reference/gio Merged gio-standalone into glib.
2007-11-26  Alexander Larsson  <alexl@redhat.com>

        * Makefile.am:
        * configure.in:
        * gio-2.0-uninstalled.pc.in:
        * gio-2.0.pc.in: 
        * gio-unix-2.0-uninstalled.pc.in:
        * gio-unix-2.0.pc.in:
	* gio/
	* docs/reference/gio
	Merged gio-standalone into glib.
	
        * glib/glibintl.h:
        * glib/gutils.c:
	Export glib_gettext so that gio can use it
	Add P_ (using same domain for now)
	Add I_ as g_intern_static_string


svn path=/trunk/; revision=5941
2007-11-26 16:13:05 +00:00
Tor Lillqvist
bdbb9b8323 ISO8859-1 is CP28591, not CP1252.
2007-11-26  Tor Lillqvist  <tml@novell.com>

	* glib/win_iconv.c: ISO8859-1 is CP28591, not CP1252.


svn path=/trunk/; revision=5939
2007-11-26 00:50:24 +00:00
Tor Lillqvist
6e0847851b Add win_iconv.c to EXTRA_DIST.
2007-11-26  Tor Lillqvist  <tml@novell.com>

	* glib/Makefile.am: Add win_iconv.c to EXTRA_DIST.


svn path=/trunk/; revision=5938
2007-11-25 23:31:58 +00:00
Tor Lillqvist
04aec5b28d Implement #491549: On Windows, always use the native API for character set
2007-11-26  Tor Lillqvist  <tml@novell.com>

	Implement #491549: On Windows, always use the native API for
	character set conversions instead of GNU libiconv. Almost all
	codesets supported by GNU libiconv exist as Windows codepages.
	One missing feature is the "C99" and "JAVA" pseudo codesets, but I
	doubt that is worth worrying about.
	
	* glib/win_iconv.c: New file. iconv() implementation for
	Windows. Placed in the public domain by Yukihiro Nakadaira
	<yukihiro.nakadaira@gmail.com>. From
	http://yukihiro.nakadaira.googlepages.com/win_iconv.zip, his
	2007-11-17 version.

	* glib/gconvert.c: Include win_iconv.c on Windows.

	* configure.in: Bypass iconv checks on Windows. 


svn path=/trunk/; revision=5937
2007-11-25 23:27:45 +00:00
Tor Lillqvist
6fdcc7ddb2 Add conditionals for non-Unix. Just g_error() unless G_OS_UNIX for now.
2007-11-25  Tor Lillqvist  <tml@novell.com>

	* glib/gtestutils.c: Add conditionals for non-Unix. Just g_error()
	unless G_OS_UNIX for now.


svn path=/trunk/; revision=5936
2007-11-25 22:47:39 +00:00
Tor Lillqvist
d2b9634cb7 Build gtestutils etc on OS_UNIX only.
2007-11-25  Tor Lillqvist  <tml@novell.com>

	* glib/Makefile.am: Build gtestutils etc on OS_UNIX only.


svn path=/trunk/; revision=5934
2007-11-25 21:39:42 +00:00
Matthias Clasen
d2f111fca7 Require gtk-doc 1.8.
2007-11-25  Matthias Clasen  <mclasen@redhat.com>

        * configure.in: Require gtk-doc 1.8.

        * glib/gasyncqueue.c:
        * glib/gdate.c:
        * glib/gfileutils.c:
        * glib/gmain.c:
        * glib/gmarkup.c:
        * glib/gregex.c:
        * glib/gtestutils.c:
        * glib/gutils.c: Use gtk-doc abbreviations for
        examples in doc comments.


svn path=/trunk/; revision=5933
2007-11-25 06:05:06 +00:00