Simon McVittie [Mon, 17 Oct 2011 12:27:03 +0000 (13:27 +0100)]
Annotate GDBusConnection private functions with thread/lock status
The thread shared between all GDBusWorker instances was variously called
the "worker thread" or "message handler thread", which I mostly changed to
"the GDBusWorker thread" to avoid ambiguity.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661992
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
Yaron Shahrabani [Sat, 22 Oct 2011 10:39:15 +0000 (12:39 +0200)]
Updated Hebrew translation.
Matej Urbančič [Fri, 21 Oct 2011 19:24:06 +0000 (21:24 +0200)]
Updated Slovenian translation
Ryan Lortie [Fri, 21 Oct 2011 18:05:10 +0000 (14:05 -0400)]
GDBusMessage: fix leak of GError
As part of the deserialisation process of a zero-length array in the
DBus wire format, parse_value_from_blob() recursively calls itself with
the expectation of failing (as can be seen by the assert immediately
following).
It passes &local_error to this always-failing call and then fails to
free it (indeed, to use it at all). The result is that the GError is
leaked.
Fix it by passing in NULL instead, so that the GError is never created
in the first place.
https://bugzilla.gnome.org/show_bug.cgi?id=662411
Ryan Lortie [Fri, 21 Oct 2011 19:00:24 +0000 (15:00 -0400)]
GVariant format string docs: fix maybe types
The documentation for maybe types failed to mention 'a' as one of the
types that was handled with a single pointer for which NULL means
"nothing". Correct that omission.
Problem caught by Shaun McCance.
Matthias Clasen [Fri, 21 Oct 2011 18:57:47 +0000 (14:57 -0400)]
Make g_ascii_strtod behave as documented
The docs explicitly state that we reset errno, so lets do that,
even if we just wrap strtod_l. Also move the argument check
out of the ifdef.
https://bugzilla.gnome.org/show_bug.cgi?id=662398
Simon McVittie [Wed, 19 Oct 2011 16:23:30 +0000 (17:23 +0100)]
GDBusConnection: check for initializedness in most public API
The only exceptions are those of the trivial getters/setters that don't
already need the initialization check for its secondary role as a memory
barrier (this is consistent with GSocket, where trivial getters/setters
don't check):
* g_dbus_connection_set_exit_on_close
* g_dbus_connection_get_exit_on_close
* g_dbus_connection_is_closed
g_dbus_connection_set_exit_on_close needs to be safe for
use before initialization anyway, so it can be set at construct-time.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661689
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
Simon McVittie [Thu, 20 Oct 2011 19:02:02 +0000 (20:02 +0100)]
GDBusConnection: document use while uninitialized as undefined behaviour
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661689
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=662208
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
Simon McVittie [Thu, 20 Oct 2011 12:12:26 +0000 (13:12 +0100)]
GDBusConnection: check for initialization where needed for thread-safety
Also document which fields require such a check in order to have correct
threading semantics.
This usage doesn't matches the GInitable documentation, which suggests
use of a GError - but using an uninitialized GDBusConnection is
programming error, and not usefully recoverable. (The GInitable
documentation may have been a mistake - GNOME#662208.) Also, not all of
the places where we need it can raise a GError.
The check serves a dual purpose: it turns a non-deterministic crash into
a deterministic critical warning, and is also a memory barrier for
thread-safety. All of these functions dereference or return fields that
are meant to be protected by FLAG_INITIALIZED, so they could crash or
return an undefined value to their caller without this, if called from a
thread that isn't the one that called initable_init() (although I can't
think of any way to do that without encountering a memory barrier,
undefined behaviour, or a race condition that leads to undefined
behaviour if the non-initializing thread wins the race).
One exception is that initable_init() itself makes a synchronous call.
We deal with that by passing new internal flags up the call stack, to
reassure g_dbus_connection_send_message_unlocked() that it can go ahead.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661689
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661992
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
Simon McVittie [Fri, 21 Oct 2011 15:02:22 +0000 (16:02 +0100)]
GDBusConnection: replace is_initialized with an atomic flag
The comment implied that even failed initialization would set
is_initialized = TRUE, but this wasn't the case - failed initialization
would only set initialization_error, and it was necessary to check both.
It turns out the documented semantics are nicer than the implemented
semantics, since this lets us use atomic operations, which are also
memory barriers, to avoid needing separate memory barriers or locks
for initialization_error (and other members that are read-only after
construction).
I expect to need more than one atomically-accessed flag to fix thread
safety, so instead of a minimal implementation I've turned is_initialized
into a flags word.
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661689
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661992
Reviewed-by: David Zeuthen <davidz@redhat.com>
Chun-wei Fan [Thu, 20 Oct 2011 06:42:51 +0000 (14:42 +0800)]
Fix VS 2008 property sheet
Missed a required ';'-sorry about this. DOH! :|
Matthias Clasen [Thu, 20 Oct 2011 01:03:43 +0000 (21:03 -0400)]
Deprecate g_atexit
This function was just not a good idea to begin with.
Its documentation gives plenty of reason not to use it.
Cosimo Cecchi [Tue, 18 Oct 2011 14:48:31 +0000 (10:48 -0400)]
desktop-app-info: annotate g_desktop_app_info_get_keywords()
https://bugzilla.gnome.org/show_bug.cgi?id=662096
Ryan Lortie [Wed, 19 Oct 2011 19:26:25 +0000 (15:26 -0400)]
more NEWS
Ryan Lortie [Wed, 19 Oct 2011 19:07:22 +0000 (15:07 -0400)]
The usual docs unbreaking...
Ryan Lortie [Wed, 19 Oct 2011 14:11:54 +0000 (10:11 -0400)]
configure.ac: join the cargo-cult of _cv_
For some reason, the setting of g_atomic_lock_free wasn't making it down
to the lower part of the configure script where glibconfig.h was being
generated when building using mingw32-configure.
If we prefix glib_cv_ to the start of the variable name (like everyone
else is doing) then it magically starts working.
I love you, automake.
Simon McVittie [Tue, 18 Oct 2011 15:19:43 +0000 (16:19 +0100)]
gdbus-non-socket test: avoid use of a GMainContext across a fork
See https://bugzilla.gnome.org/show_bug.cgi?id=658999 for why this would
be bad.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=662100
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
Simon McVittie [Tue, 18 Oct 2011 15:18:21 +0000 (16:18 +0100)]
gdbus-exit-on-close test: cover more possibilities
We didn't previously test anything except the implicit default of TRUE.
Now we test implicit TRUE, explicit TRUE, explicit FALSE, and
disconnecting at the local end (which regressed while fixing Bug #651268).
Also avoid some questionable use of a main context, which fell foul of
Bug #658999 and caused this test to be disabled in master.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=662100
Bug-NB: NB#287088
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
Simon McVittie [Wed, 19 Oct 2011 09:49:56 +0000 (10:49 +0100)]
GDBusWorker: if a read was cancelled it means we closed the connection
This was a regression caused by my previous work on GDBusWorker thread-safety
(Bug #651268). The symptom is that if you disconnect a GDBusConnection
locally, the default implementation of GDBusConnection::closed
terminates your process, even though it shouldn't do that for
locally-closed connections; this is because GDBusWorker didn't think a
cancelled read was a local close.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=662100
Bug-NB: NB#287088
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
Simon McVittie [Tue, 18 Oct 2011 15:27:21 +0000 (16:27 +0100)]
Revert "Disable two GDBus tests"
This reverts commit
05ef173466e32d8b3d212803e4a72239913a362d.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=662100
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
Ryan Lortie [Wed, 19 Oct 2011 03:26:00 +0000 (23:26 -0400)]
Fix bug in g_static_rec_mutex_unlock_full()
pthreads doesn't implement the _lock_full() and _unlock_full() calls on
recursive mutexes so we don't have it on GRecMutex either. Now that
we're using GRecMutex to implement GStaticRecMutex, we have to fake it
by keeping an internal counter of the number of locks and calling
g_rec_mutex_unlock() the appropriate number of times.
The code to do this looked like:
depth = mutex->depth;
while (mutex->depth--)
g_rec_mutex_unlock (rm);
return depth;
which unfortunately did one last decrement after mutex->depth was
already zero (leaving it equal to -1).
When locked the next time, the count would then increase from -1 to 0
and then the next _unlock_full() call would not do any calls to
g_rec_mutex_unlock(), leading to a deadlock.
https://bugzilla.gnome.org/show_bug.cgi?id=661914
Ryan Lortie [Tue, 18 Oct 2011 20:21:50 +0000 (16:21 -0400)]
gatomic: introduce G_ATOMIC_LOCK_FREE
We clean up the detection of if we should do 'real' atomic operations or
mutex-emulated ones with the introduction of a new (public) macro:
G_ATOMIC_LOCK_FREE. If defined, our atomic operations are guaranteed to
be done in hardware.
We need to use __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 to determine if our
compiler supports GCC-style atomic operations from the gatomic.h header
because we might be building a program against GLib using a different
set of compiler options (or a different compiler) than was used to build
GLib itself.
Unfortunately, this macro is not available on clang, so it has currently
regressed to using the mutex emulation. A bug about that has been
opened here:
http://llvm.org/bugs/show_bug.cgi?id=11174
Ryan Lortie [Tue, 18 Oct 2011 20:21:17 +0000 (16:21 -0400)]
gatomic: cast to the correct pointer sign
In the fallback case of the g_atomic_int_ macros we had some (gint*)
casts that should have been (guint*) casts.
Mario Blättermann [Tue, 18 Oct 2011 20:28:23 +0000 (22:28 +0200)]
[l10n] Updated German translation
David Zeuthen [Thu, 13 Oct 2011 20:53:44 +0000 (16:53 -0400)]
gio: Introduce get_sort_key() methods on GDrive, GVolume and GMount
This is needed to implement efficient and predictable proxy volume
monitors, see
https://bugzilla.gnome.org/show_bug.cgi?id=661711
for details.
Signed-off-by: David Zeuthen <davidz@redhat.com>
Javier Jardón [Sun, 2 Oct 2011 16:58:16 +0000 (17:58 +0100)]
tests/gobject: Use G_VALUE_INIT
Javier Jardón [Fri, 30 Sep 2011 16:19:50 +0000 (17:19 +0100)]
gobject: Use G_VALUE_INIT
Javier Jardón [Fri, 30 Sep 2011 16:08:15 +0000 (17:08 +0100)]
gio: Use G_VALUE_INIT
Sjoerd Simons [Sun, 16 Oct 2011 09:57:29 +0000 (10:57 +0100)]
GDBusConnection: Fix race in /gdbus/connection/life-cycle
GDBusConnection sets the closed flag in the worker thread, then adds an
idle callback (which refs the Connection) to signal this in the main
thread. The tests session_bus_down doesn't spin the mainloop, so the
"closed" signal will always fire if iterating the mainloop later (and
drops the ref when doing so). But _is_closed can return TRUE even before
signalling this, in which case the "closed" signal isn't fired and the
ref isn't dropped, causing the test to fail.
Instead simply always wait for the closed signal, which is a good thing
to check anyway and ensures the ref is closed.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661896
Reviewed-by: Matthias Clasen <mclasen@redhat.com>
Alexander Larsson [Tue, 18 Oct 2011 12:15:07 +0000 (14:15 +0200)]
Actually Don't define GLIB_COMPILATION in libgthread
Last commit was wrong, fixing it up
Alexander Larsson [Tue, 18 Oct 2011 11:34:06 +0000 (13:34 +0200)]
Don't define GLIB_COMPILATION in libgthread
This was turning all the GLIB_VARs in the glib headers into
dllexports on windows, causing all sort of nastiness. libgthread is
mostly empty now anyway, so we don't need any GLIB_COMPILATION like
flag.
Matthias Clasen [Mon, 17 Oct 2011 21:01:36 +0000 (17:01 -0400)]
Fix an include guard mismatch
Spotted by Colin Walters.
Alexander Larsson [Mon, 17 Oct 2011 21:00:29 +0000 (23:00 +0200)]
Fix up testcase broken due to g_thread_new API change
Chun-wei Fan [Mon, 17 Oct 2011 16:15:37 +0000 (00:15 +0800)]
Move _glib_get_locale_dir to ggettext.c
-Move _glib_get_locale_dir to ggettext.c, as Matthias suggested
-Made up for the headers that needed to be included in ggettext.c to avoid
C4013 (implicit declaration of ...) errors/warnings
Piotr Drąg [Mon, 17 Oct 2011 16:31:48 +0000 (18:31 +0200)]
Updated POTFILES.in
Chun-wei Fan [Mon, 17 Oct 2011 06:54:50 +0000 (14:54 +0800)]
Fix gio.symbols
g_simple_action_get_parameter_type is now static, so this symbol needs to
be removed from here...
Chun-wei Fan [Mon, 17 Oct 2011 06:53:58 +0000 (14:53 +0800)]
GLib: Add forgotten includes and build fixes
-gcharset.c, genviron.c, gunicollate.c: Some headers were missed in those
files that triggered C4013 warnings/errors (aka. implicit declaration
of ... in GCC). Make up for them here.
-gwin32.h: Only define g_win32_get_package_installation_directory/
g_win32_get_package_installation_subdirectory as macros
(alias of g_win32_get_package_installation_directory_utf8/
g_win32_get_package_installation_subdirectory_utf8) on Win64 (x64) as
g_win32_get_package_installation_directory/
g_win32_get_package_installation_subdirectory have seperate existing
implmentations for Win32-this is a long-standing problem but was covered-
up by G_DISABLE_DEPRECATED, which we are stopping to use as of 2.31.0.
Ryan Lortie [Mon, 17 Oct 2011 14:54:50 +0000 (10:54 -0400)]
Revert "Bug 652827 - glib-2.29.8 no longer builds with mingw.org's toolchain"
This reverts commit
349212211247781e7bec43b95cb57dddc1d0e5b1.
Chun-wei Fan [Mon, 17 Oct 2011 09:47:00 +0000 (17:47 +0800)]
Update VS property sheets
Some new headers were added...
Chun-wei Fan [Mon, 17 Oct 2011 09:18:20 +0000 (17:18 +0800)]
glib/tests/thread.c: Add config guards
Not all systems come with unistd.h and sys/time.h, so use config guards
on them so that they are only included when available.
Chun-wei Fan [Mon, 17 Oct 2011 08:40:44 +0000 (16:40 +0800)]
Update VS property sheets
gcache.h is now a deprecated header, so up the "install" part for it.
Matthias Clasen [Mon, 17 Oct 2011 06:14:18 +0000 (02:14 -0400)]
More include cleanups
Chun-wei Fan [Mon, 17 Oct 2011 06:17:53 +0000 (14:17 +0800)]
Update VS property sheets
Stop using G_DISABLE_DEPRECATED as there are now warnings for usage of
deprecated APIs/items in GLib
Matthias Clasen [Mon, 17 Oct 2011 05:59:35 +0000 (01:59 -0400)]
include cleanup
Matthias Clasen [Mon, 17 Oct 2011 05:52:10 +0000 (01:52 -0400)]
Make things compile again
Matthias Clasen [Mon, 17 Oct 2011 05:50:00 +0000 (01:50 -0400)]
Move gettext variations into their own files
Matthias Clasen [Mon, 17 Oct 2011 05:30:31 +0000 (01:30 -0400)]
Reshuffle some functions between gutils and gfileutils
Move filename-related functions to gfileutils, and move
size formatting functions to gutils.
Matthias Clasen [Mon, 17 Oct 2011 05:30:09 +0000 (01:30 -0400)]
include cleanup
Matthias Clasen [Mon, 17 Oct 2011 05:11:56 +0000 (01:11 -0400)]
Trivial
Matthias Clasen [Mon, 17 Oct 2011 04:33:54 +0000 (00:33 -0400)]
Reshuffle genviron.c
Split win32 functions off into their own section, instead
of having large and unwieldy ifdef sections inside each function.
Also move the compat versions of env functions over from gutils.c
Ryan Lortie [Mon, 17 Oct 2011 01:59:55 +0000 (21:59 -0400)]
push G_THREADS_MANDATORY over the cliff
This was used as an optimisation for the macro hackery that used to live
in gthread.h. If a particular library or program knew that it could
rely on thread support being enabled, it would allow for static
evaluation of conditionals in some of those macros.
Since the macros are dead and thread support is now always-on, we can
get rid of this bit of legacy.
Ryan Lortie [Mon, 17 Oct 2011 01:53:03 +0000 (21:53 -0400)]
gobject/gio: some last missed statics/inclues
Ryan Lortie [Mon, 17 Oct 2011 01:50:26 +0000 (21:50 -0400)]
gthread/: fix up declarations
g_thread_init() is now a deprecated API, so drop G_DISABLE_DEPRECATED
from the CFLAGS for gthread/. Add the missing declaration for
g_thread_init_with_errorcheck_mutexes() back to deprecated/gthread.h.
Ryan Lortie [Mon, 17 Oct 2011 00:58:02 +0000 (20:58 -0400)]
Add private prototype for g_thread_init_glib()
This function was never put in a header and was only used internally
from libgthread, but we should keep the symbol around to avoid
triggering any false-positives on ABI checkers.
For -Wmissing-prototypes compatibility with this unusual case, we should
add a private prototype in the .c file just before.
Ryan Lortie [Mon, 17 Oct 2011 01:24:45 +0000 (21:24 -0400)]
gio static fixups
Ryan Lortie [Mon, 17 Oct 2011 01:17:10 +0000 (21:17 -0400)]
static and #include fixups in glib/
Ryan Lortie [Mon, 17 Oct 2011 01:13:22 +0000 (21:13 -0400)]
genviron: #include fixups
Ryan Lortie [Mon, 17 Oct 2011 01:11:11 +0000 (21:11 -0400)]
more 'static' adding in testcases
No dead code found this time...
Ryan Lortie [Mon, 17 Oct 2011 01:10:23 +0000 (21:10 -0400)]
contexts test: don't use deprecated GCond wait API
Ryan Lortie [Mon, 17 Oct 2011 00:57:40 +0000 (20:57 -0400)]
Mark some functions 'static' in glib/tests
This has uncovered two unused testcases in option-context.c. They are
currently broken and require more investigation (which is probably why
they are unused).
OKANO Takayoshi [Mon, 17 Oct 2011 00:25:08 +0000 (09:25 +0900)]
Updated Japanese translation
Ryan Lortie [Sun, 16 Oct 2011 23:21:35 +0000 (19:21 -0400)]
README: Add note about gobject->gthread situation
Ryan Lortie [Sun, 16 Oct 2011 23:17:52 +0000 (19:17 -0400)]
gobject.pc: remove dependency on gthread
GObject no longer uses gthread, so libgthread should no longer be
included in the linker flags of programs built against GObject.
Ryan Lortie [Sun, 16 Oct 2011 23:14:18 +0000 (19:14 -0400)]
drop -uninstalled.pc files
These were meant to provide the ability to use GLib directly out of its
build tree but have a couple of rather serious limitations that prevent
their serious use:
- these files only worked with programs built using libtool
- for non-trivial uses, other environment variables will need to be
setup to allow GLib to function properly
- the system doesn't stack well when attempting to use multiple
libraries all uninstalled
The jhbuild --prefix= style system works much better in every way, so we
remove this old hack.
Ryan Lortie [Sun, 16 Oct 2011 23:11:00 +0000 (19:11 -0400)]
gitignore
Ryan Lortie [Sun, 16 Oct 2011 23:08:59 +0000 (19:08 -0400)]
gthread: move test cases to glib/
Ryan Lortie [Sun, 16 Oct 2011 23:04:19 +0000 (19:04 -0400)]
tests: merge gthread/ and glib/ atomic tests
Ryan Lortie [Sun, 16 Oct 2011 23:01:55 +0000 (19:01 -0400)]
glib/tests/atomic: convert to proper gtester test
Matthias Clasen [Sun, 16 Oct 2011 22:43:22 +0000 (18:43 -0400)]
Also clean up includes
Matthias Clasen [Sun, 16 Oct 2011 22:40:58 +0000 (18:40 -0400)]
Move charset and locale name functions to their own files
They did not really belong into either gutils or gutf8.
Matthias Clasen [Sun, 16 Oct 2011 21:37:29 +0000 (17:37 -0400)]
Add deprecation annotations to mem chunk apis
Matthias Clasen [Sun, 16 Oct 2011 21:01:26 +0000 (17:01 -0400)]
Move version APIs out of gutils
Just another cleanup.
Matthias Clasen [Sun, 16 Oct 2011 20:52:24 +0000 (16:52 -0400)]
Move GTrashStack out of gutils.[hc]
Reducing the mess in gutils, and moving docs inline
at the same time. Double win.
Matthias Clasen [Sun, 16 Oct 2011 20:23:18 +0000 (16:23 -0400)]
Pass correct data to fatal log handlers
This was pointed out by John Ralls in bug 653052.
He also provided the test case.
Martin Pitt [Wed, 17 Aug 2011 06:57:15 +0000 (08:57 +0200)]
Clarify g_spawn_*() behaviour without full path
Document the previously uncovered case of calling g_spawn_async_with_pipes()
without a full path but no G_SPAWN_SEARCH_PATH. This runs programs from the
current directory, which might be unexpected and even dangerous in some corner
cases.
https://bugzilla.gnome.org/show_bug.cgi?id=656621
Matthias Clasen [Sun, 16 Oct 2011 18:34:16 +0000 (14:34 -0400)]
Add a tests of some GVfs functions
https://bugzilla.gnome.org/show_bug.cgi?id=656621
Jiro Matsuzawa [Sun, 16 Oct 2011 16:54:33 +0000 (01:54 +0900)]
Updated Japanese translation
Jiro Matsuzawa [Sat, 17 Sep 2011 02:30:01 +0000 (11:30 +0900)]
Updated Japanese translation
Matthias Clasen [Sun, 16 Oct 2011 04:08:42 +0000 (00:08 -0400)]
Add app lauch environment test
Matthias Clasen [Sun, 16 Oct 2011 03:58:30 +0000 (23:58 -0400)]
Add g_get_codeset test
Matthias Clasen [Sun, 16 Oct 2011 03:58:18 +0000 (23:58 -0400)]
Add GAsyncQueue unit test
Matthias Clasen [Sun, 16 Oct 2011 03:27:28 +0000 (23:27 -0400)]
Move g_get_codeset next to g_get_charset
g_get_codeset is a close relatove to g_get_charset, and up to now
it lived a shadowy existence without any header presence.
Matthias Clasen [Sun, 16 Oct 2011 00:06:32 +0000 (20:06 -0400)]
Include genviron.h where necessary
Matthias Clasen [Sat, 15 Oct 2011 23:39:14 +0000 (19:39 -0400)]
And fix the syntax, too
Matthias Clasen [Sat, 15 Oct 2011 23:38:10 +0000 (19:38 -0400)]
Forgotten file
Matthias Clasen [Sat, 15 Oct 2011 22:23:07 +0000 (18:23 -0400)]
Drop unused copy of _g_getenv_nomalloc
Simon McVittie [Thu, 13 Oct 2011 16:39:03 +0000 (17:39 +0100)]
GDBusConnection: warn that direct access to the stream is a bad idea
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661679
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Torsten Schönfeld [Tue, 16 Aug 2011 17:11:43 +0000 (19:11 +0200)]
Add two annotations to gio
https://bugzilla.gnome.org/show_bug.cgi?id=656679
Simon McVittie [Tue, 4 Oct 2011 09:14:35 +0000 (10:14 +0100)]
Document that types are limited to 64 KiB
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=659916
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Kean Johnston [Sat, 15 Oct 2011 21:57:23 +0000 (17:57 -0400)]
GIOModule: Use G_SEARCHPATH_SEPARATOR_S instead of ":"
https://bugzilla.gnome.org/show_bug.cgi?id=661257
Giovanni Campagna [Sat, 15 Oct 2011 21:54:41 +0000 (17:54 -0400)]
GKeyFile: improve introspection annotations
Ensure that all methods that take or return arrays are annotated
(including length). Mark ref, unref and free methods as (skip).
https://bugzilla.gnome.org/show_bug.cgi?id=590808
Giovanni Campagna [Sat, 15 Oct 2011 21:51:25 +0000 (17:51 -0400)]
Turn GKeyFile into a boxed for introspection
Using the new refcounting API, introduce a boxed type wrapping
GKeyFile and expose it introspection bindings in glib-types.h.
Christian Persch [Mon, 25 May 2009 13:07:27 +0000 (15:07 +0200)]
GKeyFile: Add refcounting API
Adds g_key_file_ref and g_key_file_unref, to be used by a future
GKeyFile boxed type for language bindings.
Based on the patch by Christian Persch and Emmanuele Bassi.
Author: Christian Persch
Signed-off-by: Johan Dahlin
Signed-off-by: Giovanni Campagna
https://bugzilla.gnome.org/show_bug.cgi?id=590808
Matthias Clasen [Sat, 15 Oct 2011 21:31:47 +0000 (17:31 -0400)]
Add 'Since 2.32' indexes to gio and gobject docs
Dan Winship [Sat, 15 Oct 2011 20:59:59 +0000 (16:59 -0400)]
GAppLaunchContext: add environment-manipulating functions
Add functions for manipulating the environment under which a
GAppLaunchContext will launch its children, to avoid thread-related
bugs with using setenv() directly.
FIXME: win32 side isn't implemented yet
https://bugzilla.gnome.org/show_bug.cgi?id=659326
Matthias Clasen [Sat, 15 Oct 2011 20:50:23 +0000 (16:50 -0400)]
Misc doc formatting fixes
Matthias Clasen [Sat, 15 Oct 2011 20:28:07 +0000 (16:28 -0400)]
Add tests for new g_environ_ functions
Matthias Clasen [Sat, 15 Oct 2011 20:13:08 +0000 (16:13 -0400)]
Move environment-related functions into their own files
gutils.[hc] is a bit of a grab bag, so lets start cleaning
things up by moving all the environment-related functions
into separate genviron.[hc] files.
The private _g_getenv_nomalloc has been moved to its sole caller.
Dan Winship [Sat, 15 Oct 2011 19:52:28 +0000 (15:52 -0400)]
gutils: Add functions for working with environment arrays
When spawning a child process, it is not safe to call setenv() before
the fork() (because setenv() isn't thread-safe), but it's also not
safe to call it after the fork() (because it's not async-signal-safe).
So the only safe way to alter the environment for a child process from
a threaded program is to pass a fully-formed envp array to
exec*/g_spawn*/etc.
So, add g_environ_getenv(), g_environ_setenv(), and
g_environ_unsetenv(), which act like their namesakes, but work on
arbitrary arrays rather than working directly on the environment.
http://bugzilla.gnome.org/show_bug.cgi?id=659326
Ryan Lortie [Sat, 15 Oct 2011 17:27:46 +0000 (13:27 -0400)]
Add to the pitfalls: fork() and daemon()