1 2007-03-19 Bill Holmes <billholmes54@gmail.com>
3 * src/gpath.c (g_path_is_absolute) : Adding a case for '/'
6 * src/gpath.c (g_get_user_name) : On Windows add a check for %USERNAME%
9 * src/gstr.c (g_strsplit, g_strsplit_set): Change to remove truncation
10 errors with MSVC build.
12 * src/gstr.c (g_filename_to_uri, g_filename_from_uri): Fixes to handle
15 * src/gstr.c (g_ascii_strncasecmp): Convert each character to lower case
18 * src/gunicode.c (g_get_charset): Implement for Windows.
20 Contributed under MIT/X11 license.
22 2008-03-12 Geoff Norton <gnorton@novell.com>
24 * src/gutf8.c: Implement g_ucs4_to_utf16 and g_utf16_to_ucs4 as
25 asserts. They're needed to build mono with eglib.
26 * src/gutil.h: Add a few missing function declarations to the header.
27 * src/gspawn.c: Some darwin implementations don't have crt_externs.h
28 So we'll just define _NSGetEnviron() ourselves.
29 * Makefile.am: Dont build test when cross compiling.
30 * configure.ac: Define CROSS_COMPILING when cross compiling.
31 Undefine _FORTIFY_SOURCE on arm-apple-darwin as the headers it
32 requires are not available.
34 2008-01-15 Andreas Faerber <andreas.faerber@web.de>
36 * configure.ac: Add default G_BREAKPOINT implementation.
37 Fix typo in breakpoint CPU output.
39 2007-12-23 Zoltan Varga <vargaz@gmail.com>
41 * src/glib.h: Include <limits.h>. Fixes #350482.
43 2007-11-21 Dick Porter <dick@ximian.com>
45 * src/gslist.c (g_slist_find_custom): Implement
47 * src/glist.c (g_list_find_custom): Implement
49 * test/list.c: Test g_list_find_custom()
51 * test/slist.c: Test g_slist_find_custom()
53 2007-11-20 Dick Porter <dick@ximian.com>
55 * src/gstr.c: Implement g_strsplit_set() and re-implement
56 g_strsplit() so it passes the additional tests. (g_strsplit()
57 should treat multi-char delimiters as just a single token, rather
58 than a set of delimiters.)
60 * src/gslist.c: Implement g_slist_index(), g_slist_nth() and
63 * test/string-util.c: Test g_strsplit_set() and more tests for
66 * test/slist.c: Test g_slist_nth() and
69 2007-11-06 Geoff Norton <gnorton@novell.com>
71 * configure.ac: Check for libiconv_open as the previous check was failing against
72 some versions of libiconv.
74 2007-11-06 Andreas Faerber <andreas.faerber@web.de>
76 * test/Makefile.am: Fix noinst_PROGRAMS for automake 1.6.3
79 2007-11-06 Geoff Norton <gnorton@novell.com>
81 * configure.ac: Determing if glib-2.0 is installed and set HAVE_GLIB appropriately
82 * test/Makefile.am: Only build test-glib if glib-2.0 is available
84 2007-11-05 Geoff Norton <gnorton@novell.com>
86 * configure.ac: Check for getpwent_r and wether libiconv is needed to be linked.
87 Also look to see if we can use export-dynamic in the test suite.
88 * test/Makefile.am: Get LDFLAGS from configure instead of setting them.
89 * src/gerror.c: Implement g_clear_error.
90 * src/glib.h: Only use the format, ... convention is HAVE_C99_SUPPORT is available.
91 * src/gpath.c: Only use the getpwent_r codepath if getpwent_r is available.
92 * src/gspawn.c: Define environ to call _NSGetEnviron() on Apple.
93 * src/Makefile.am: Remove -Werror so we dont fail on different function declarations.
94 Portions of all of the above are from Andreas Faerber & Jonathan Chambers
96 2007-10-31 Jonathan Chambers <joncham@gmail.com>
98 * src/ghashtable.c: Add g_hash_table_foreach_steal.
99 * src/garray.c: Add g_array_remove_index_fast.
100 * src/gpath.c (g_path_is_absolute): Handle windows paths.
101 * src/glib.h: Add g_hash_table_foreach_steal and g_array_remove_index_fast
103 Contribution is licensed as MIT/X11.
105 2007-06-13 Jonathan Chambers <joncham@gmail.com>
107 * src/gunicode.c: Add g_unichar_isxdigit and g_unichar_xdigit_value.
108 * src/gmisc.c: Add g_win32_getlocale stub.
109 * src/glib.h: Add declarations of above functions,
110 GFreeFunc typedef, and CLAMP, GUINT_TO_LE, and threading
113 * test/string-util.c: Fix warning.
114 * test/utf8.c: Add test for g_unichar_xdigit_value.
116 Contribution is licensed as MIT/X11.
118 2007-05-05 Aaron Bockover <abockover@novell.com>
121 * src/glib.h: Added g_ascii_tolower implementation; make g_ascii_strdown
122 use it to do the transformation
124 * test/string-util.c: Added a test for g_ascii_strdown
126 2007-04-27 Jonathan Chambers <joncham@gmail.com>
128 * src/gstr.c: Fix off by one error in g_strdup allocation.
130 2007-04-27 Jonathan Chambers <joncham@gmail.com>
132 * src/eglib-config.hw: Forgot to add for msvc build.
133 * src/vasprintf: Forgot to add for msvc build.
135 2007-04-27 Jonathan Chambers <joncham@gmail.com>
137 * src/gstr.c: Fix off by one error for NULL terminator.
139 2007-04-27 Jonathan Chambers <joncham@gmail.com>
141 Combined patch from Michael Jerris <mike@jerris.com> and me.
142 * winconfig.h: Config file for msvc builds.
143 * configure.ac: Add AC_CHECK_HEADERS for getopt.h, sys/time.h,
144 sys/wait.h, and pwd.h.
146 * src/gspawn.c: Include config.h and use HAVE_* macros.
147 * src/eglib-config.h.in: Add inclusion guards.
148 * src/ghashtable.c: Fix warnings.
149 * src/gmisc.c: Windows implementation of g_getenv, g_setenv,
151 * src/gpath.c: Include config.h and use HAVE_* macros.
152 * src/gmarkup.c: Fix warnings.
153 * src/gptrarray.c: Fix warnings.
154 * src/gstr.c: Fix warnings and use HAVE_* macros.
155 * src/glib.h: Move macros to eglib-config.h and include it.
156 * src/gdate.c: Implement g_get_current_time on windows.
157 * src/gpattern.c: Fix warnings.
158 * src/gdir.c: Implement g_dir on windows.
159 * src/gfile.c: Implement mkstemp and g_file_test on windows.
160 * src/gtimer.c: Implement g_timer on windows.
161 * src/gmodule.c: Fix warnings.
162 * src/gunicode.c: Fix warnings.
163 * src/gutf8.c: Fix warnings.
165 * test/ptrarray.c: Fix warnings.
166 * test/string.c: Fix warnings.
167 * test/list.c: Fix warnings.
168 * test/pattern.c: Use HAVE_* macros.
169 * test/dir.c: Use HAVE_* macros.
170 * test/file.c: Use HAVE_* macros and use system specific files for tests.
171 * test/test.c: Fix warnings and use HAVE_* macros.
172 * test/timer.c: Use HAVE_* macros.
173 * test/string-util.c: Fix warnings.
174 * test/test.h: Supress warnings on msvc.
175 * test/module.c: Use HAVE_* macros.
176 * test/utf8.c: Fix warnings.
177 * test/spawn.c: Use HAVE_* macros.
178 * test/driver.c: Fix warnings and use HAVE_* macros.
179 * test/path.c: Use HAVE_* macros and use system specific files for tests.
180 * test/sizes.c: Fix warnings.
182 2007-04-24 Jonathan Chambers <joncham@gmail.com>
184 Patch from Michael Jerris <mike@jerris.com>
185 * src/gspawn.c: Start msvc build.
186 * src/gpath.c: Start msvc build.
187 * src/gmarkup.c: Start msvc build.
188 * src/gshell.c: Start msvc build.
189 * src/gstr.c: Start msvc build.
190 * src/glist.c: Start msvc build.
191 * src/glib.h: Start msvc build.
192 * src/gdate.c: Start msvc build.
193 * src/gpattern.c: Start msvc build.
194 * src/gdir.c: Start msvc build.
195 * src/gfile.c: Start msvc build.
196 * src/gtimer.c: Start msvc build.
197 * src/gmodule.c: Start msvc build.
198 * src/gunicode.c: Start msvc build.
200 2007-01-27 Robert Jordan <robertj@gmx.net>
202 * test/Makefile.am: Add linker option to be able to
203 load symbols from the main program.
204 * test/module.c: Clean-ups.
206 2007-01-26 Robert Jordan <robertj@gmx.net>
208 * configure.ac: Add PLATFORM_WIN32 conditional.
209 * src/Makefile.ac: Use PLATFORM_WIN32 conditional for psapi, iconv
210 * test/module.c, test/tests.h, test/Makefile.am: New test for gmodule.
211 * src/gmodule.h: Add G_MODULE_{IMPORT|EXPORT} defines.
212 * src/gmodule.c (g_module_symbol): Implement in-proc symbol lookup
214 * src/gmodule.c: Add GModule.main_module, consider it in
216 * src/gpath.c (g_get_home_dir): Add dummy Win32 implementation to
219 2006-11-03 Miguel de Icaza <miguel@novell.com>
221 * src/gpath.c (g_path_get_dirname): If the pathname starts with a
224 * test/string-util.c (test_strlcpy): Add new test.
226 * src/gunicode.c (g_filename_from_utf8): g_strlcpy needs the full
227 size, with the extra zero at the end; Fixes the stack trace
230 2006-10-30 Miguel de Icaza <miguel@novell.com>
232 * test/utf8.c (test_utf8_seq): Add new failing test.
234 2006-10-30 Atsushi Enomoto <atsushi@ximian.com>
236 * src/gutf8.c : several fixes:
237 - fixed incorrect mb_size clear and mb_remain computation.
238 - initialize items_written to 0 for error case.
239 - in utf8_to_utf16_len differentiate error messages completely.
240 - in g_utf8_to_utf16 use guchar instead of gchar.
241 * test/utf8.c : added test case string in test_utf8_seq() to
242 both test_utf8_to_utf16() and test_utf16_to_utf8().
244 2006-10-21 Miguel de Icaza <miguel@novell.com>
246 * src/gunicode.c (g_filename_from_utf8): Use g_strlcpy here.
248 * src/gmarkup.c (g_markup_parse_context_parse): Do not dereference
249 null values here. This gets things a little bit further in
250 corlib, but not too far.
252 * src/gdir.c (g_dir_read_name): Do not return . or ..
254 * src/gstr.c (g_ascii_xdigit_value): Make this into a function,
255 thanks to Paolo for pointing the problem with the double macro
258 * src/gmodule.c (g_module_open): Actually return NULL if we fail
259 to load the module (was hiding the real bug in the pinvoke tests).
261 (g_module_build_path): Do not prepend "lib" if the "lib" is part
264 * src/gstr.c (g_strsplit): this routine has some non-expected
265 behavior, if the string begins with the delimiter, it will return
266 an empty first string, unlike strtok
268 * src/gpath.c (g_path_get_dirname): Return "." as a dirname for
269 paths that do not contain a directory.
271 2006-10-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
273 * test/array.c: new test for insertion in the middle of other values.
274 * src/garray.c: fixed destination index.
276 2006-10-18 Miguel de Icaza <miguel@novell.com>
278 * src/gpath.c (g_build_path): Do not append terminator if the next
281 * src/gutf8.c (g_utf8_to_utf16): Include trailing zero as
283 (g_utf16_to_utf8): Include trailing zero as documented.
285 2006-10-17 Miguel de Icaza <miguel@novell.com>
287 * src/gstr.c (g_strdown): Actually move.
289 * src/gmarkup.c (g_markup_parse_context_parse): Accept dots in the
290 sequence, reset the state after a closing element.
292 * src/garray.c (g_array_insert_vals): Shift the elements the
295 (g_array_insert_vals): Should actually use the
296 number of elements to insert.
298 * test/array.c: Add new test case, this was happening in the JIT.
300 * Add _GNU_SOURCE at configure time, remove from sources.
302 * src/gstr.c (g_strsplit): Empty strings return a 0 value vector.
304 * src/glib.h (G_MAXINT64, G_MININT64): Add another set of macros
305 for the support stuff.
307 Move private prototypes elsewhere
309 * src/glib.h (g_thread_init): Adding missing brace
310 (g_list_next): remove ; from the macro definition.
312 2006-10-17 Miguel de Icaza <miguel@novell.com>
314 * src/gutf8.c: internal methods
316 * src/ghashtable.c: internal methods.
318 2006-10-16 Miguel de Icaza <miguel@novell.com>
320 * src/gerror.c (g_propagate_error): Implement.
322 * src/gstr.c (g_strjoinv, g_ascii_strncasecmp): implement.
324 * test/string-util.c (test_ascii_strncasecmp): test
326 2006-10-15 Miguel de Icaza <miguel@novell.com>
328 * configure.in: Fix detection of platforms the [3456] stuff does
329 not work inside autoconf.
331 * src/eglib-config.h.in: Make G_BREAKPOINT into a function-macro
333 * src/glib.h (offsetof): Mono sources depend on this, bring this
334 from the standard definition. Redefine G_STRUCT_OFFSET in terms
337 * src/glib.h (G_STRUCT_OFFSET): fix macro definition.
340 * src/sizes.c: Add test.
342 * src/gshell.c: Make it build
344 2006-10-14 Miguel de Icaza <miguel@novell.com>
346 * src/glib.h: add various _TO_LE and _FROM_LE macros.
348 * test/endian.c: tests for endian conversion macros.
350 2006-10-09 Miguel de Icaza <miguel@novell.com>
352 * src/gmodule.h: Move definitions of gmodule to gmodule.h because
353 Mono expects it there.
355 Mon Oct 9 12:59:16 CEST 2006 Paolo Molaro <lupus@ximian.com>
357 * src/ghashtable.c: s/to_prime/g_spaced_primes_closest/g
358 and put the array in readonly memory.
359 * src/gstr.c: fixed the build and made array const.
360 * src/gmodule.c: fixed thinko.
362 2006-10-08 Miguel de Icaza <miguel@novell.com>
364 * src/gstr.c (g_strdup): should allow NULL as an argument.
366 2006-10-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
368 * test/string-util.c:
371 * src/glib.h: implemented g_strescape.
373 2006-10-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
375 * test/string-util.c:
379 * src/glib.h: implemented g_strlcpy.
381 2006-10-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
383 * test/string-util.c:
386 * src/glib.h: implemented g_strdelimit.
388 2006-10-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
390 * test/spawn.c: add search path flag when running ls.
391 * src/gspawn.c: g_spawn_command_line_sync searches the program in the
392 PATH if it's not an absolute path.
394 2006-10-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
396 * test/string-util.c:
397 * src/glib.h: implement g_ascii_xdigit_value and tests.
399 2006-10-06 Miguel de Icaza <miguel@novell.com>
401 * src/gstr.c (g_ascii_strdown): Implement.
403 * str/glib.c (g_log_set_handler): empty.
405 (GMemVTable): define, empty, ignored.
408 * src/gunicode.c (g_convert): Add bytes_read, bytes_written
409 support; Small fixes to avoid valgrind errors.
411 (g_utf8_validate): Add, based on the libxml code.
413 gstr.c: implement g_strdown.
415 2006-10-05 Miguel de Icaza <miguel@novell.com>
417 * src/gunicode.c: Some work in progress to implement g_convert
418 (which is needed by g_locale_to_utf8).
420 2006-09-18 Miguel de Icaza <miguel@novell.com>
422 * test/string-util.c (test_filename_from_uri): tests for new
425 * src/gstr.c (g_filename_to_uri, g_filename_from_uri): implement.
427 2006-09-14 Atsushi Enomoto <atsushi@ximian.com>
429 * src/gutf8.c, test/utf8.c : EOL fix.
431 2006-09-04 Miguel de Icaza <miguel@novell.com>
433 * src/gmarkup.c: The leak fixing commit.
435 * src/gmarkup.c (g_markup_parse_context_end_parse): Add missing
437 (g_markup_parse_context_free): Implement.
438 (parse_attributes): Store the value, not the attribute name
440 Properly check the /> section.
441 (g_markup_parse_context_parse): When checking for error, use the
442 "error!=NULL && *error != NULL" upon return from callbacks,
443 it is only then that its valid to check for *error for error
445 (g_markup_parse_context_parse): Add comment processing.
447 Only release one element of the list.
449 * test/markup.c: Incorporate the kind of code that is used in Mono
450 for domain loading; Will test the rest later.
452 2006-09-01 Miguel de Icaza <miguel@novell.com>
454 * src/gmarkup.c (g_markup_parse_context_parse): Add text parsing
455 support, and end-element support; not tested yet.
457 2006-09-01 Atsushi Enomoto <atsushi@ximian.com>
459 * gutf8.c : bad allocation size. multiply sizeof gchar/gunichar2.
461 2006-09-01 Atsushi Enomoto <atsushi@ximian.com>
463 * gutf8.c : when error is null, utf8_to_utf16_len() and
464 utf16_to_utf8_len() could return -1, so return NULL for those
465 cases in g_utf8_to_utf16() and g_utf16_to_utf8().
467 2006-09-01 Miguel de Icaza <miguel@novell.com>
469 * src/gmarkup.c: Builds and does minimal parsing.
471 * test/markup.c: Sample test cases I have been using
473 2006-08-31 Atsushi Enomoto <atsushi@ximian.com>
476 src/gerror.c : added g_set_error().
478 g_utf8_to_utf16() and g_utf16_to_utf8() implementation.
479 * src/glib.h : added all above, and some dependent bits.
480 * src/Makefile.am : added gutf8.c.
481 * TODO: removed above.
483 test/tests.h : added utf8 tests.
484 * test/utf8.c : test for g_utf8_to_utf16 and g_utf16_to_utf8.
485 It still needs more tests e.g. for multibytes.
487 2006-08-31 Gonzalo Paniagua Javier <gonzalo@ximian.com>
489 * src/gspawn.c: small touch-ups and make read/write EINTR-proof.
491 2006-08-31 Gonzalo Paniagua Javier <gonzalo@ximian.com>
493 * test/file.c: remove useless test.
495 * test/spawn.c: new g_spawn_async_with_pipes test.
496 * src/glib.h: Modified file.
497 * src/gspawn.c: implemented g_spawn_async_with_pipes. Needs fine tuning.
499 2006-08-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
501 * TODO: Modified file.
509 * src/gfile.c: implemented g_dir_*, unix version.
511 2006-08-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
514 * test/Makefile.am: Modified file.
516 * src/Makefile.am: Modified file.
518 * src/gpattern.c: implemented the 3 pattern matching functions used.
520 * test/ptrarray.c: fix the compare function to work with qsort.
525 * src/gpath.c: made valgrind happy.
527 2006-08-26 Gonzalo Paniagua Javier <gonzalo@ximian.com>
531 * src/gfile.c: implemented g_file_test. Changed the default mask to
534 2006-08-26 Raja R Harinath <rharinath@novell.com>
536 * src/sort.frag.h (digit): Declare here based on externally
537 provided typedef 'list_node'.
538 (MAX_DIGITS): Use 'sizeof (list_node)'.
539 * src/gslist.c (list_node): Declare instead of 'digit'.
540 * src/glist.c: Likewise.
542 * test/slist.c (verify_sort): Verify the length of the list too.
543 (test_slist_sort): Free the correct list.
544 * test/list.c: Likewise.
545 * src/sort.frag.h (MAX_DIGITS): Rename from N_DIGITS.
546 (combine_sort): Change 'max_pos' argument to more natural
548 (increment): Likewise. Use 'n_digits' to avoid reading at an
549 offset that hasn't been initialized.
550 (do_sort): Remove memset.
552 2006-08-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
557 * src/gfile.c: implement g_file_open_tmp.
559 2006-08-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
563 * src/gdate.c: New file.
564 * src/gfile.c: New file.
565 * src/Makefile.am: implemented g_file_get_contents and
569 * test/file.c: New file.
570 * test/Makefile.am: tests for the above.
572 2006-08-26 Raja R Harinath <rharinath@novell.com>
574 * src/sort.frag.h: Add copyright notice and some explanation.
575 (increment): Remove null check.
576 (combine_digits): Add 'list' argument to seed the summation.
577 (do_sort): Use the empty or singleton tail as the seed, rather
578 than calling 'increment'.
580 2006-08-25 Raja R Harinath <rharinath@novell.com>
582 * TODO: Remove 'List' entries.
583 * src/Makefile.am (libeglib_la_SOURCES): Add sort.frag.h.
584 * src/sort.frag.h: New. Implements a "generic" bottom-up "counting"
585 mergesort that works both on singly- and doubly-linked lists.
586 * src/gslist.c (g_slist_sort): Use it.
587 * src/glist.c (g_list_sort): Likewise.
588 * src/glib.h (g_slist_sort, g_list_sort): Declare.
589 * test/slist.c, test/list.c: Add basic testcases.
591 2006-08-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
593 * src/gspawn.c: propagate errors from reads.
594 * src/gpath.c: an empty PATH is like a NULL one.
596 2006-08-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
604 * src/Makefile.am: implemented GTimer.
606 2006-08-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
613 * src/Makefile.am: initial implentation of g_spawn_command_line_sync.
614 Still need better error handling, but works for the most part.
616 2006-08-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
618 * src/garray.c: grow faster so that the 'big' test does not crawl.
620 2006-08-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
623 * src/gqueue.c: plugged leaks.
625 2006-08-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
628 * src/gpath.c: when PATH is not defined, the current dir is used.
631 2006-08-25 Alp Toker <alp@atoker.com>
633 * src/gstr.c: g_strv_length() should return guint, not gint
634 * src/glib.h: Add g_strv_length() prototype
636 2006-08-24 Miguel de Icaza <miguel@novell.com>
638 * src/gpath.c (g_get_home_dir, g_get_tmp_dir, g_get_user_name,
639 g_get_prgname, g_set_prgname): implemented.
643 * src/gpath.c (g_get_current_dir): Implement.
645 (g_find_program_in_path, g_path_is_absolute): implement.
647 Add g_path_get_dirname, g_path_get_basename
649 * src/gpath.c: Path routines
651 2006-08-23 Miguel de Icaza <miguel@novell.com>
653 * src/gerror.c: Implement.
655 * src/glist.c (g_list_sort): Remove routine instead of hoping that
656 it wont crash when we run it.
658 2006-08-23 Raja R Harinath <rharinath@novell.com>
660 * src/glist.c (g_list_insert_before): Avoid non-head declaration.
662 * test/slist.c (test_slist_insert_before): Add.
663 * src/gslist.c (g_slist_insert_before): Append if 'sibling' is null.
665 * test/list.c (test_list_insert_before): Add test for return value
666 of g_list_insert_before.
667 * test/Makefile.am (test_eglib_LDADD): Refer to the .la file so as
668 to rebuild test if eglib changes.
669 * src/glist.c (new_node, disconnect_node): New helpers that
670 maintain doubly-linked list invariants.
671 (g_list_prepend, g_list_append): Express in terms of new_node.
672 (g_list_insert_before): Likewise. Fix return value when inserting
673 in the middle of the list.
674 (g_list_concat): Reorganize to make more compact.
675 (g_list_nth): Likewise.
676 (g_list_nth_data): Don't segfault if 'n' is too large.
677 (g_list_remove): Rewrite using _find and disconnect_node.
678 (g_list_remove_link): Don't traverse list: use disconnect_node.
679 (g_list_insert_sorted): Rewrite to make more compact. Use new_node.
680 (g_list_copy): Likewise.
681 (_prepend, _concat): Remove.
682 * src/gslist.c (insert_after, find_prev, find_prev_link):
684 (g_slist_copy): Simplify slightly, using insert_after.
685 (g_slist_concat): Reorganize to make more compact.
686 (g_slist_find): Likewise.
687 (g_slist_insert_sorted): Likewise.
688 (g_slist_remove): Rewrite using find_prev.
689 (g_slist_remove_link): Rewrite using find_prev_link.
690 (g_slist_remove_all, g_slist_insert_before): New.
692 2006-08-21 Duncan Mak <duncan@a-chinaman.com>
694 * src/gqueue.c: GQueue implementation.
695 * src/glib.h: Add prototypes.
696 * src/Makefile.am (libeglib_la_SOURCES): Include gqueue.c.
699 * test/Makefile.am (SOURCES):
700 * test/tests.h (DEFINE_TEST_GROUP_INIT_H): add tests for GQueue.
702 2006-08-21 Aaron Bockover <abockover@novell.com>
704 * src/gstr.c: fixed bug/invalid read/write on malloc-only case (no
705 realloc/delimiter token not found); use memcpy instead of strncpy for
708 * test/test.c (run_group): allow running specific tests under a group;
709 added copied g_strsplit/g_strfreev from EGlib source as eg_strsplit
710 and eg_strfreev to avoid performance skews in the driver
712 * test/driver.c: allow user-specified group name to contain specific
713 test to run under the group as 'group_name:test1,test2,...testN'
715 * test/string-util.c: Added more g_strsplit tests
723 * test/hashtable.c: make test names shorter (no need to prefix with
724 the group since it runs under the group)
726 2006-08-21 Miguel de Icaza <miguel@novell.com>
728 * src/glib.h (g_hash_table_new_full): Add missing prototype.
729 Replace g_free(x) with plain free, so it can be used as a function
733 * src/ghashtable.c: Add rehashing.
735 * test/hashtable.c: Add a bunch of extra tests.
737 * src/goutput.c: Fix g_log so it actually formats the data.
739 * src/ghashtable.c (g_hash_table_new): The glib test suite
740 uncovered a bunch of bugs, the g_hash_table_new should actually
743 (g_hash_table_remove, g_hash_table_foreach_remove): Fixed bugs
746 2006-08-20 Aaron Bockover <abockover@novell.com>
748 * src/gmisc.c: added g_setenv, g_getenv, g_unsetenv
750 * src/gstr.c: added g_snprintf, g_sprintf, g_fprintf, g_printf
752 * src/glib.h: added macros for above va_args printf functions
754 * src/Makefile.am: added gmisc.c
756 * test/whats-implemented: script to see what needs to be implemented
758 2006-08-20 Chris Toshok <toshok@ximian.com>
760 * test/array.c (test_array_big): add a test from the glib
763 2006-08-20 Chris Toshok <toshok@ximian.com>
765 * test/tests.h: add array tests to the mix.
767 * test/array.c: a few array tests.
769 * src/glib.h: add array prototypes.
771 * src/garray.c: initial array foo.
773 * test/Makefile.am (SOURCES): add array.c
775 * src/Makefile.am (libeglib_la_SOURCES): add garray.c
777 2006-08-19 Aaron Bockover <abockover@novell.com>
779 * src/gstring.c: optimize and generalize reallocation by providing
780 a GROW_IF_NECESSARY macro, do not use strcpy/strcat as they are
781 very, very slow; GString is now much closer to GLib's implementation
782 in terms of performance
784 * test/string.c: added speed-specific tests to beat on reallocation code
786 * test/test-both: run make if the test drivers don't exist
788 2006-08-19 Jonathan Chambers <jonathan.chambers@gmail.com>
790 * src/gmodule.c: Add gmodule support for windows and fix
791 windows build. Contribution is licensed as MIT/X11.
793 2006-08-19 Aaron Bockover <abockover@novell.com>
795 * test/driver.c: Added --debug mode that allows for testing all paths
796 of the driver without actually running real tests; runs only the 'fake'
797 test, which does nothing; useful for running the driver through valgrind
801 * test/fake.c: Added fake test for valgrinding the driver
803 * test/ptrarray.c: update sort test
805 2006-08-19 Aaron Bockover <abockover@novell.com>
807 * test/test-both: added --help
809 2006-08-19 Aaron Bockover <abockover@novell.com>
811 * test/driver.c: added -n mode to show only raw global run times,
812 which is useful for scripts (test-both --speed-compare)
814 * test/test-both: added --speed-compare mode
816 * test/README: updated with information on --speed-compare
818 2006-08-19 Aaron Bockover <abockover@novell.com>
820 * test/test.c: do not print times if -t is not passed
822 * test/driver.c: removed use of GList from the driver to avoid skews due
823 to performance differences between GLib and EGLib
825 2006-08-19 Aaron Bockover <abockover@novell.com>
827 * test/test.c: Perform iterations at the test level, only output one
828 report for all iterations of tests in a group to produce more usable
829 output; add timing for the tests and group; added get_timestamp for
832 * test/test.h: Removed run_test as it should only be called from
833 run_group, added get_timestamp
835 * test/Makefile.am: Added -DDRIVER_NAME
837 * test/test-both: simple script to run both drivers with the same options
839 * test/driver.c: Iterations are now run at the test level, show a global
840 status (OK/FAIL) indicator
842 * test/README: Updated
844 * configure.ac: Renamed from configure.in as configure.in naming
845 convention is deprecated in favor of configure.ac
847 * autogen.sh: s/configure.in/configure.ac/
849 2006-08-19 Miguel de Icaza <miguel@novell.com>
851 * Makefile.am: Removed MAINTAINERCLEANFILES that was too
852 aggresive, it failed make distcheck and the resulting tarball was
855 * src/glib.h: remove the various GPOINTER_TO_*, G*_TO_POINTER,
856 GSIZE_FORMAT macros, and move them into src/eglib-config.h
858 Moved also gssize and gsize to be arch specific. This should fix
859 the 32/64 problems that Jon Chambers reported.
861 * configure.in: test for pointer size, define the various values
862 depending on 32 vs 32/64 worlds, might need further porting in the
865 Change package name to eglib
867 * test/slist.c, test/list.c, test/hashtable.c: Update tests to use
870 * test/string-util.c: fix leak for valgrind tests.
872 * test/tests.h: New size test, for testing datatypes.
874 * test/sizes.c: New tests.
876 2006-08-19 Aaron Bockover <abockover@novell.com>
878 * test/README: Added quick guide on adding new tests/groups to the
879 driver and some examples on how to perform various tests with the driver
881 2006-08-18 Aaron Bockover <abockover@novell.com>
883 * test/driver.c: Added getopt support and code timing, among other
884 nice features to make testing/profiling easier
886 * test/test.c: Add support for suppressing output (quiet) and
887 define RESULT, FAILED, and OK
890 * src/glist.c: Added g_list_nth_data implementation
893 * test/string-util.c:
897 * test/list.c: Use RESULT, FAILURE, and OK for tests
899 2006-08-18 Miguel de Icaza <miguel@novell.com>
901 * src/gstring.c (g_string_truncate): Implement truncate.
902 (g_string_prepend): implement.
904 Fix various bugs uncovered by new tests.
906 * src/glib.h: introduce gssize type, the signed one. Important.
908 * src/eglib-config.h (G_OS_): Add the G_OS_UNIX and G_OS_WIN32
909 defines that we can use to check on the host OS.
911 2006-08-18 Aaron Bockover <abockover@novell.com>
914 * test/driver.c: Support pass/fail logging on tests to show group report
916 2006-08-18 Aaron Bockover <abockover@novell.com>
919 * test/test.h: Added result() to be used in place of g_strdup_printf(),
920 it's shorter to write and allows the duped string to be freed safely;
921 added license header to file
923 * test/driver.c: Added license header to file
925 * test/string-util.c:
928 * test/list.c: Use result() in place of g_strdup_printf(), it's nicer
930 2006-08-18 Aaron Bockover <abockover@novell.com>
932 * src/gptrarray.c: Implemented g_ptr_array_sort
934 * test/ptrarray.c: Added sort test
936 * test/driver.c: Added --help; support running N iterations and allow
937 selecting which test groups to run; uses the test group table in tests.h
939 * test/tests.h: Added group table
942 * test/test.c: Using a Group structure and table, removed run_groups
943 as we only need run_group now
945 * test/slist.h: Removed, not needed, tests/groups defined in tests.h
947 2006-08-18 Miguel de Icaza <miguel@novell.com>
949 * src/unicode.c: New file, to host unicode code, it will throw as
950 this code is no longer used in the Mono runtime anyways.
952 * src/glib.h: Use stdint.h types, a lot of the good stuff is
955 2006-08-18 Duncan Mak <duncan@a-chinaman.com>
957 * src/glist.c (g_list_remove, g_list_remove_link): Implemented.
959 * src/gslist.c (g_slist_remove): Remember to set the next pointer
960 to NULL when the item to remove is the first item in the list.
962 2006-08-18 Duncan Mak <duncan@a-chinaman.com>
964 * src/glist.c: Implemented. Missing remove,
965 remove_link and insert_before.
967 * test/list.c: Tests for GList.
969 2006-08-17 Aaron Bockover <abockover@novell.com>
971 * src/gptrarray.c: Implemented g_ptr_array_remove and
972 g_ptr_array_remove_index
974 * test/other: Removed, rewritten in Makefile.am
976 * test/Makefile.am: Build test-eglib against local eglib and
977 test-glib against GLib 2.0 (replaces 'other')
979 * test/ptrarray.c: Added tests for g_ptr_array_remove and
980 g_ptr_array_remove_index
982 2006-08-17 Duncan Mak <duncan@a-chinaman.com>
984 * src/gslist.c: Added MIT license.
985 (g_slist_insert_sorted): Forgot the case where the data is
986 appended to the end of the list.
988 * test/slist.c (test_slist_insert_sorted): Fix the test.
990 2006-08-17 Aaron Bockover <abockover@novell.com>
992 * src/gptrarray.c: Added g_ptr_array_set_size implementation
994 * test/ptrarray.c: Added test for g_ptr_array_set_size
996 2006-08-17 Miguel de Icaza <miguel@novell.com>
998 * src/glib.h: A handful of extra macros
1000 * configure.in, src/eglib-config.h.in: Set some system-specific
1001 settings that are probed at configure time.
1003 2006-08-17 Aaron Bockover <abockover@novell.com>
1005 * src/gptrarray.c: Added beginnings of GPtrArray (alloc, free, add, iterate)
1007 * src/glib.h: Added GPtrArray signatures
1009 * src/Makefile.am: Added gptrarray.c to build
1014 * test/Makefile.am: Add ptrarray tests for available functionality
1016 2006-08-17 Aaron Bockover <abockover@novell.com>
1019 * test/test.c: Added group iterator/test driver functionality
1021 * test/driver.c: Added groups to run using new test functionality
1025 * test/string-util.h: Test group definitions for string util/hashtable
1029 * test/hash.c: Added test definition table
1031 * test/Makefile.am: Added -Wall -Werror -D_FORTIFY_SOURCE=2
1033 * src/gstr.c: Added implementation for g_str_has_prefix, g_str_has_suffix
1035 * src/glib.h: Added missing function signatures
1037 * src/Makefile.am: added -D_FORTIFY_SOURCE=2
1039 2006-08-17 Duncan Mak <duncan@a-chinaman.com>
1041 * src/gslist.c (g_slist_remove_link): I misread the function
1042 signature. Re-implemented.
1043 (g_slist_delete_link): Implemented.
1044 (g_slist_reverse): Implemented.
1045 (g_slist_insert_sorted): Implemented.
1047 2006-08-17 Duncan Mak <duncan@a-chinaman.com>
1049 * src/gslist.c (g_slist_find):
1052 (g_slist_remove_link): Implemented.
1054 * test/slist.c: Tests for GSList.
1056 2006-08-17 Raja R Harinath <harinath@gmail.com>
1058 * src/gslist.c (g_slist_free_1): New. Free a single list node.
1059 (g_slist_free): Use it to free the list nodes. Don't free the
1060 data, since the list doesn't own it.
1061 (g_slist_append): Convert into a one-liner.
1062 (g_slist_foreach): Remove redundant null check.
1063 (g_slist_last): Actually return the last node.
1064 (g_slist_copy): Simplify.
1065 * src/gslist.h (g_slist_free_1): Add.
1067 2006-08-16 Duncan Mak <duncan@a-chinaman.com>
1071 * src/gslist.h: First attempt at implementing GSList, incomplete.
1073 * src/Makefile.am (libeglib_la_SOURCES): add gslist.c
1074 * src/glib.h: Add GFunc definition. #include the new gslist.h.
1076 2006-08-16 Miguel de Icaza <miguel@novell.com>
1078 * src/Makefile.am: Added -Wall,-Werror, corrected lots of
1081 * src/gstring.c: Gstring implementation.
1083 * test/str.c (test_gstring): string tests.
1085 2006-08-16 Aaron Bockover <abockover@novell.com>
1087 * src/gstr.c: Added g_strsplit implementation
1089 * test/driver.c: Run the split test
1091 * test/str.c: Added a test for g_strsplit
1095 * test/Makefile.am: Added MAINTAINERCLEANFILES
1097 2006-08-16 Miguel de Icaza <miguel@novell.com>
1099 * src/gouput.c: Implement some output routines, update missing
1102 * test: Add test driver, and initial tests.
1104 2006-08-15 Miguel de Icaza <miguel@novell.com>
1106 * src/ghashtable.c: Implement most of this, it is completely
1107 untested at this point.