summaryrefslogtreecommitdiff
path: root/gobject/gsourceclosure.c
AgeCommit message (Collapse)Author
2023-10-04gobject: use g_once_init_enter_pointer for GType initializersAlex Richardson
GType is either an integer or a pointer, so we have to use the _pointer version here to support architectures such as Morello. Helps: https://gitlab.gnome.org/GNOME/glib/-/issues/2842 See also: https://gitlab.gnome.org/GNOME/glib/-/merge_requests/3578
2022-06-01Add SPDX license headers for LGPL-2.1-or-later to various filesPhilip Withnall
These have all been added manually, as I’ve finished all the files which I can automatically detect. All the license headers in this commit are for LGPL-2.1-or-later, and all have been double-checked against the license paragraph in the file header. Signed-off-by: Philip Withnall <pwithnall@endlessos.org> Helps: #1415
2020-11-20gobject: Drop use of volatile from get_type() macrosPhilip Withnall
http://isvolatileusefulwiththreads.in/c/ It’s possible that the variables here are only marked as volatile because they’re arguments to `g_once_*()`. Those arguments will be modified in a subsequent commit. Signed-off-by: Philip Withnall <pwithnall@endlessos.org> Helps: #600
2018-04-27all: Remove trailing newlines from g_message()/g_warning()/g_error()sPhilip Withnall
All those logging functions already add a newline to any message they print, so there’s no need to add a trailing newline in the message passed to them. Signed-off-by: Philip Withnall <withnall@endlessm.com> Reviewed-by: nobody
2017-11-29gobject: Minor typo fix in a g_critical() warningPhilip Withnall
Signed-off-by: Philip Withnall <withnall@endlessm.com>
2017-05-24gobject/: LGPLv2+ -> LGPLv2.1+Sébastien Wilmet
All gobject/*.{c,h} files have been processed. gmarshal.c and gmarshal.h don't have a license header. https://bugzilla.gnome.org/show_bug.cgi?id=776504
2015-06-04Prevent race condition in g_io_condition_get_typeStefan Ekenberg
Prevents race condition in function g_io_condition_get_type by ensuring that the initialization section for 'etype' is executed only once during a program's life time, and that concurrent threads are blocked until initialization completes. This changes solves the problem that concurrent threads could execute the check 'etype == 0' before any of them had initialized it, which in turn meant that multiple threads would then attempt to register the "GIOCondition" type. https://bugzilla.gnome.org/show_bug.cgi?id=750386
2014-01-31Updated FSF's addressDaniel Mustieles
2013-07-21gsourceclosure.c: Fix build on WindowsChun-wei Fan
GPid is a HANDLE (aka void *) on Windows, not an int, so treat pid accordingly on Windows, as using pid as a gulong directly would likely be undesirable on Windows https://bugzilla.gnome.org/show_bug.cgi?id=704447
2013-07-17gsourceclosure: fix idle/timeout/signal closures, add child watch supportDan Winship
And add a test for all source types. https://bugzilla.gnome.org/show_bug.cgi?id=704267
2013-07-13gsourceclosure: Add support for GUnixSignalWatchSource and GUnixFDSourceDan Winship
https://bugzilla.gnome.org/show_bug.cgi?id=701511
2013-07-13gsourceclosure: use g_cclosure_marshal_genericDan Winship
For the glib-defined source types, and any source type that defines a closure callback but not a closure marshal, use g_cclosure_marshal_generic. And then remove all the other remaining source closure marshals. https://bugzilla.gnome.org/show_bug.cgi?id=701511
2013-01-20Install an invalidation notifier for GClosure in g_source_set_closure()Giovanni Campagna
The point of g_source_set_closure() is getting memory management right, including handling closures disappearing from the outside (for example because a runtime they refer to is being shutdown). This means that sources with an associated closure should remove themselves from the main loop and free memory when the closure is invalidated. https://bugzilla.gnome.org/show_bug.cgi?id=692034
2011-10-18gobject: Use G_VALUE_INITJavier Jardón
2010-11-26Add g_source_set_dummy_callback()Dan Winship
Use g_source_set_closure() and g_close_set_meta_marshal() to allow setting a do-nothing callback on any source. https://bugzilla.gnome.org/show_bug.cgi?id=634239
2010-08-18Use G_DEFINE_[BOXED|POINTER]_TYPE instead of handwritten codeChristian Persch
Now that we have convenience macros to implement boxed and pointer types, use them.
2010-07-07gobject/: fully remove gobjectalias hacksRyan Lortie
2008-06-22remove trailing whitespace from newly added gtk-doc comments andMichael Natterer
2008-06-22 Michael Natterer <mitch@imendio.com> * *.c: remove trailing whitespace from newly added gtk-doc comments and reformatted some where they contained overly long or ill-formatted lines. svn path=/trunk/; revision=7090
2008-06-22moved includes back to the top of the files (before gtk-doc SECTIONMichael Natterer
2008-06-22 Michael Natterer <mitch@imendio.com> * *.c: moved includes back to the top of the files (before gtk-doc SECTION comments). Add "config.h" in all files and move system included before glib includes. Remove trailing whitespace from SECTION comments and did some reformatting where lines were overly long, no documentation content was changed. svn path=/trunk/; revision=7089
2008-06-21Migrating docs.Stefan Kost
* docs/reference/gobject/tmpl/gclosure.sgml: * gobject/gboxed.h: * gobject/gclosure.c: * gobject/gclosure.h: * gobject/gobject.c: * gobject/gsourceclosure.c: * gobject/gsourceclosure.h: Migrating docs. svn path=/trunk/; revision=7069
2005-03-14Make work again.Matthias Clasen
2005-03-14 Matthias Clasen <mclasen@redhat.com> * abicheck.sh: Make work again. * gsourceclosure.c: Fix a typo. Make PLT-reduction work with gcc4, and don't include everything in gobjectalias.h: * gobject.symbols: Group symbols by header and source file. * makegobjectalias.pl: Protect definitions by the same preprocessor symbols used to guard the headers. Move the alias declarations to a separate file which is produced when calling makegalias.pl -def * Makefile.am (gobjectaliasdef.c): Add a rule to build this file. * *.c: Include gobjectalias.h after the other i GLib headers, include gobjectaliasdef.c at the bottom.
2004-11-08removed wrap_g_io_channel_ref() hack, since g_io_channel_ref() has aManish Singh
Mon Nov 8 10:47:41 2004 Manish Singh <yosh@gimp.org> * gobject/gsourceclosure.c: removed wrap_g_io_channel_ref() hack, since g_io_channel_ref() has a compatible API now.
2004-09-16Implement the same PLT reduction technique used in GTK+:Matthias Clasen
2004-09-16 Matthias Clasen <mclasen@redhat.com> Implement the same PLT reduction technique used in GTK+: * Makefile.am: Generate gobjectalias.h from gobject.symbols. (BUILT_SOURCES): Add gobjectalias.h. * makegobjectalias.pl: Script to generate gobjectalias.h. * *.c: Include gobjectalias.h
2004-01-11wrap g_io_channel_ref in a function that returns the passed in GIOChannel,Manish Singh
Sun Jan 11 15:34:35 2004 Manish Singh <yosh@gimp.org> * gsourceclosure.c: wrap g_io_channel_ref in a function that returns the passed in GIOChannel, so we aren't abusing GBoxedCopyFunc semantics. Fixes bug #131076.
2003-02-07Remove all docs from gobject at Tims request. Documentation is only forMatthias Clasen
2003-02-07 Matthias Clasen <maclas@gmx.de> * gtypemodule.c: * gtype.c: * gsourceclosure.c: * gparamspecs.c: * gparam.c: * gobject.c: * gsignal.c: Remove all docs from gobject at Tims request. Documentation is only for weenies anyway...
2001-11-22Improve the detection of invalid includes by moving the test outside theOwen Taylor
Mon Nov 19 14:35:56 2001 Owen Taylor <otaylor@redhat.com> * *.h: Improve the detection of invalid includes by moving the test outside the duplicate include guards. * gsourceclosure.c (g_source_set_closure): Doc fix.
2001-10-30Fix documentation. Document g_log_domain_glib, gunichar, gunichar2,Matthias Clasen
* gobject/gsourceclosure.c (g_source_set_closure): Fix documentation. * glib/tmpl/messages.sgml, glib/tmpl/unicode.sgml: Document g_log_domain_glib, gunichar, gunichar2, GUnicodeType, GUnicodeBreakType.
2001-09-10Removed is_refcounted and GBoxedInitFunc fromAlex Larsson
2001-09-10 Alex Larsson <alexl@redhat.com> * gobject/gboxed.[ch]: * gobject/gsourceclosure.c: Removed is_refcounted and GBoxedInitFunc from g_boxed_type_register_static().
2001-09-03updates for 1.3.7 release.Tim Janik
Tue Sep 4 01:50:24 2001 Tim Janik <timj@gtk.org> * NEWS: updates for 1.3.7 release. Tue Sep 4 01:49:18 2001 Tim Janik <timj@gtk.org> * gsourceclosure.c: make closure_callback_funcs static, added some g_return_if_fail() statements.
2001-09-03Implement.Owen Taylor
Mon Aug 27 14:55:27 2001 Owen Taylor <otaylor@redhat.com> * gsourceclosure.[ch] (g_source_set_closure): Implement. * gsourceclosure.[ch]: Add GType's for GIOChannel, GIOCondition. Mon Aug 27 14:56:12 2001 Owen Taylor <otaylor@redhat.com> * glib/gmain.h: Add closure_marshal/closure_callback fields to GSourceFuncs for use by g_source_set_closure(). * glib/gmain.c glib/giounix.c glib/giowin32.c glib/gmain.h: Export the SourceFuncs vtables so GObject can use them to figure out closure callbacks/marshallers for the default source types.