Matthias Clasen
05c2aeaf33
Add a Since: tag
2009-09-04 20:41:25 -04:00
Benjamin Otte
24bec5c5bd
Bug 594034 - Add g_mkstemp_full()
...
This function exposes more variables than g_mkstemp() and therefor
allows more flexibility when creating temporary files.
The intended use is gio's code for g_file_replace() (see next patch)
2009-09-04 22:45:07 +02:00
Dan Winship
8212aadac7
g_time_val_from_iso8601: handle timezoneless dates
...
per ISO 8601:2004 4.2.5.2
Based on a patch from Andy Shevchenko
http://bugzilla.gnome.org/show_bug.cgi?id=589491
2009-09-01 09:40:03 -04:00
Matthias Clasen
3ba64e72cf
Read /dev/urandom unbuffered
...
To avoid wasting entropy. Bug 593232.
2009-08-27 22:59:05 -04:00
Christian Persch
8ef30758d5
Preserve errno
...
When using errno in g_set_error with _(), preserve errno. Bug #592457 .
2009-08-22 15:08:43 +02:00
Benjamin Otte
981d14e85c
Improve documentation for g_error_matches()
2009-08-18 11:35:01 +02:00
Tor Lillqvist
1b298d6a1b
Avoid gcc warning on Windows
...
Avoid "function declaration isn't a prototype" warnings from gcc 4.4
in the Windows-specific code.
2009-08-14 23:04:55 +03:00
Alexander Larsson
d20a188b12
Only fsync if the existing file is > 0 bytes
...
This means we don't sync in the case where we created an (empty)
temp file and now replace it with the data.
This fixes (among other things) the performance of trashing files.
2009-08-11 20:26:12 +02:00
Craig Loftus
a465508e2d
Migrate gbase64 docs from SGML template to inline comments
...
Fixes bug #589649 .
Signed-off-by: David King <davidk@openismus.com>
2009-08-10 15:40:01 +02:00
Behdad Esfahbod
ba6be2035d
[gbsearcharray] Use malloc() instead of realloc(NULL,...)
2009-07-20 16:03:25 -04:00
Matthias Clasen
91925d2cf0
Another possible error code clash, yay
2009-07-10 13:11:28 -04:00
Matthias Clasen
c23536cefe
Improve g_str_equal docs
...
Add a reference to g_strcmp0(), cf. bug 587938.
2009-07-10 11:18:31 -04:00
Ryan Lortie
593ea5f6b0
Ensure GTree is consistent after _destroy()
...
See comment #9 on bug 587773
2009-07-07 21:29:46 +01:00
Ryan Lortie
10ba0c2e5c
Merge branch 'tree-refcount'
2009-07-07 09:45:31 +01:00
Matthias Clasen
d5a5130519
Minor doc fix
2009-07-05 23:55:00 -04:00
Ryan Lortie
8792d862db
GTree: switch to GSlice, add refcounts ( #587773 )
2009-07-05 12:30:54 +01:00
Dan Winship
4363f1932f
Add g_main_context_push_thread_default() etc
...
This allows applications to use async methods from other threads, or
in multiple independent main loops.
http://bugzilla.gnome.org/show_bug.cgi?id=579984
2009-07-01 09:02:23 -04:00
Christian Dywan
49172a71aa
Display '-h' in --help output and accept '-h' and -?'
...
'-h' is the preferred short version of '--help' now and displayed
in '--help' but for backwards compatibility '-?' is still supported.
If existing code uses '-h' for something else, GOptionContext will
not override it.
Fixes bug 556706.
2009-06-28 02:45:50 +02:00
Jani Monoses
09c3f6dd4b
Fix C++ warnings in g_error() code
...
Put space before ending semicolon in for(;;) ; to avoid C++ build warnings.
Closes bug 586928.
2009-06-27 11:03:47 +03:00
David Zeuthen
0ccd18bc83
Bug 586675 – Runtime library location
...
Introduce an option to specify the runtime location for libraries via
a relative path to libdir.
Signed-off-by: David Zeuthen <davidz@redhat.com>
2009-06-23 12:58:35 -04:00
Matthias Clasen
440bf5bee5
Use pipe2 when available
...
This avoids a small window for races between pipe and fdset.
Reported in bug 579933 by Thiago Macieira.
2009-06-19 23:44:29 -04:00
Ryan Lortie
4c791f49e5
GMappedFile: add refcounting, switch to GSlice
...
- add g_mapped_file_ref() and g_mapped_file_unref().
- deprecate g_mapped_file_free().
- move to GSlice for allocating the GMappedFile struct.
2009-06-18 15:01:18 -04:00
Alexander Larsson
91bdccff75
Add g_reload_user_special_dirs_cache ( #541276 )
...
This is useful for nautilus that changes the xdg-user-dirs files.
2009-06-15 13:18:22 +02:00
Matthias Clasen
6224d3d2ec
Fix g_string_chunk_insert_len to accept nuls
...
Contrary to what the documentation says, g_string_chunk_insert_len
was stopping at the first nul. Also add a test. Fixes bug 585088.
2009-06-10 23:50:45 -04:00
Michael Meeks
059ec81c9e
move start_element emission out into a new (inlined) function, so
...
the alloca'd memory is released on return, rather than slowly blowing
the stack.
2009-06-09 11:32:44 +01:00
Hans Breuer
4a50bab276
Define fstat() for msvc build
2009-05-30 15:33:14 +02:00
Hans Breuer
75ef018248
Updated msvc build files
2009-05-30 15:29:23 +02:00
Matthias Clasen
00151ec0e1
Fix a locking problem in g_main_context_iterate()
...
We failed to ensure that the context is locked on every exit of
the function. This fixes bug 583324.
2009-05-27 12:04:35 -04:00
Christian Persch
37bd225d7b
Fix grammar in error message
...
Bug #583198 .
2009-05-23 18:00:06 +02:00
Christian Persch
76ebe6c069
Plug a mem leak
...
Bug #583196 .
2009-05-23 17:59:54 +02:00
Yeti
01b79d67ef
Make g_error_new_valist public
...
Bug #569024 .
2009-05-23 17:52:58 +02:00
Christian Persch
1cbdd2495d
Preserve errno when using g_set_error with _() and g_strerror()
2009-05-20 13:47:55 +02:00
Stefan Kost
0a280dadec
docs: fix typo
2009-05-20 14:29:49 +03:00
Matthias Clasen
79ef3d3264
Correct g_utf8_to_utf16 docs
...
As pointed out in bug 580932, len is counting bytes here.
2009-05-02 22:44:52 -04:00
Matthias Clasen
2dfce32422
Accept NULL as empty string list
...
Fixes bug 580656.
2009-05-02 22:41:19 -04:00
Dan Winship
92ac8d165e
Misc warning fixes
...
glib/pcre/pcre_ucp_search_funcs.c, glib/pcre/pcre_valid_utf8.c: add
back missing config.h includes, and this time add them to the copies
in glib/update-pcre/ too so they don't get lost again on the next PCRE
update.
glib/garray.c, glib/gbase64.c: fix signed/unsigned pointer casts
gio/xdgmime/xdgmimeglob.c: remove unused variable
gio/tests/live-g-file.c: fix printf args on x86_64
tests/Makefile.am, tests/regex-test.c: remove redundant -DENABLE_REGEX
2009-05-01 10:37:45 -04:00
Michael Meeks
83699774fa
Patch originally committed only to the ChangeLog & tests ...
...
Bug 572508 – gmarkup speedup ...
* glib/gmarkup.c: Various optimizations: do less allocations by
keeping a pool of GStrings, do in-place unescaping, avoid redundant
utf-8 validation.
2009-05-01 15:23:23 +01:00
David Zeuthen
402847c887
Bug 580450 – Reference counting and boxed types for arrays
...
Add reference counting and boxed types for GArray, GByteArray and GPtrArray.
Signed-off-by: Matthias Clasen <mclasen@redhat.com>
2009-04-29 11:17:23 -04:00
David Zeuthen
49dfb50afc
Bug 580453 – Hash and equal functions for gint64 and gdouble
2009-04-27 13:27:44 -04:00
Dan Winship
6a3b4fa05a
Add hostname-related utilities in glib/ghostutils.h
...
Functions for converting between UTF-8 IDNs (Internationalized Domain
Names) and their ASCII-Compatible Encodings, plus a function to recognize
IP addresses. Part of #548466 .
2009-04-22 08:36:02 -04:00
Stefan Kost
dda20bccbf
goption: format section docs according to gtk-doc rules and fixes broken xml
2009-04-21 23:21:28 +03:00
Stefan Kost
57bd24dc49
goption: document that some option args need to be freed by the callee
...
Option arguments where the result is stored in a string or string array need to
be freed by the owner of the option group. Fixes #578363 .
2009-04-21 17:50:00 +03:00
Stefan Kost
2026c232b3
goption: move docs from tmpl folder to inline comments
2009-04-21 16:35:26 +03:00
Peter Kjellerstedt
efc2cdbfc9
Fix parsing of timezones
...
Make g_time_val_from_iso8601 handle timezones with minutes correctly;
also accept comma as a fraction separator. (#578369 )
2009-04-08 10:26:11 -04:00
Paolo Borelli
e8a42bb81c
Regex leak on error path
...
Don't leak the GRegex struct when g_regex_new() fails.
2009-04-03 00:04:39 -04:00
Tobias Mueller
20df6b6e88
Mark glib_gettext as string translation function
...
Make glib_gettext with G_GNUC_FORMAT to avoid warnings with
-Wformat -Wformat-nonliteral.
Signed-off-by: Matthias Clasen <mclasen@redhat.com>
2009-04-01 21:51:00 -04:00
Hagen Schink
86aa49594f
fix a typo in g_io_channel_flush docs
...
Refer to the correct return values.
Signed-off-by: Matthias Clasen <mclasen@redhat.com>
2009-04-01 21:30:51 -04:00
Matthias Clasen
a6ebda3d69
Copy a va_list when using it multiple times. Reported by Wim Lewis.
...
* glib/gmessages.c (g_logv): Copy a va_list when using it
multiple times. Reported by Wim Lewis.
svn path=/trunk/; revision=8021
2009-03-29 19:08:57 +00:00
Ryan Lortie
8df23d2283
trivial spelling/whitespace fixes
...
svn path=/trunk/; revision=8011
2009-03-17 23:03:33 +00:00
Alexander Larsson
6cff88ba18
Bug 575555 – Use fsync() when replacing files to avoid data loss on
...
2009-03-16 Alexander Larsson <alexl@redhat.com>
Bug 575555 – Use fsync() when replacing files to avoid data loss on crash
* configure.in:
Look for fsync().
* glib/gfileutils.c:
(write_to_temp_file):
fsync temp file if destination file exists
2009-03-16 Alexander Larsson <alexl@redhat.com>
Bug 575555 – Use fsync() when replacing files to avoid data loss on crash
* glocalfileoutputstream.c:
(g_local_file_output_stream_close):
(_g_local_file_output_stream_replace):
fsync temp file before closing if replacing target file
svn path=/trunk/; revision=7991
2009-03-16 16:03:13 +00:00