Commit Graph

2998 Commits

Author SHA1 Message Date
Matthias Clasen
c7f38cd277 Mark another function as static 2011-01-18 00:06:55 -05:00
Matthias Clasen
67e112cce6 Mark a function as static 2011-01-18 00:06:05 -05:00
Matthias Clasen
d2347f34fd Move GMarkup docs inline 2011-01-17 23:46:20 -05:00
Ray Strode
e8120dc4ce datetime: Show 12 instead of 0 for 12h hour format
The 12h mode hour format is computed by taking the
24h mode hour format modulo 12.

The conversion results in 12 noon getting erroneously
converted to 0.

This commit makes noon get the same special handling
as midnight.
2011-01-17 14:31:34 -05:00
Ray Strode
a437c5e768 tests: add format test case for noon hour in 12h mode
It currently displays it as "0" instead of "12", so this
test case demonstrates the bug.
2011-01-17 14:31:34 -05:00
Javier Jardón
a583405f66 docs: gvariant-core: g_variant_normalise -> g_variant_get_normal_form() 2011-01-14 17:54:04 +00:00
Javier Jardón
6c0491841e gvariant-core: Fix typo
g_variant_create_from_data -> g_variant_new_from_data
2011-01-14 17:25:07 +00:00
Matthias Clasen
b67d9cb7ee Add regex test cases
These come from https://bugzilla.gnome.org/show_bug.cgi?id=638894
2011-01-07 12:07:19 -05:00
Matthias Clasen
51ac0c6c85 Avoid possible parameter name clashes in GVariant
https://bugzilla.gnome.org/show_bug.cgi?id=638349
2011-01-05 19:42:13 -05:00
Christian Persch
3d824065b8 Add g_get_locale_variants()
Make _g_compute_locale_variants() public as g_get_locale_variants().

Bug #635998.
2011-01-05 22:57:20 +01:00
Christian Persch
be8899bfe6 Make _g_compute_locale_variants return a char** directly
Bug #635998.
2011-01-05 22:49:21 +01:00
Matthias Clasen
9686d82daf Fix build on old kernels
Cope with BTRFS_SUPER_MAGIC not being defined.
2011-01-04 09:38:14 -05:00
Emmanuele Bassi
52c831099e gtester-report: Add an optional 'revision' node
In order to distinguish reports generated from a specific revision of a
projects it would be good if gtester-report handled a <revision> node in
the XML.

The payload is free-form, just like for the other nodes under <info>.

https://bugzilla.gnome.org/show_bug.cgi?id=631980
2010-12-28 16:35:12 +00:00
Matthias Clasen
b27ecf79e8 Document that g_variant_builder_add_value consumes a floating ref
Patch by Mikkel Kamstrup Erlandsen, bug
https://bugzilla.gnome.org/show_bug.cgi?id=634569
2010-12-28 00:19:45 -05:00
Matthias Clasen
702a96c281 Fix a possible crash in g_io_channel_read_chars
Patch by Rui Matos, https://bugzilla.gnome.org/show_bug.cgi?id=637759
2010-12-28 00:08:56 -05:00
Ryan Lortie
99fe4b1da7 Bug 637544 - Skip fsync() on btrfs
For g_file_set_contents() we fsync() before renaming the file over the
original in order to ensure that we don't end up with an invalid file.
btrfs provides this guarantee for us without the fsync() so skip it
there.
2010-12-20 20:50:19 -05:00
Xavier Claessens
8d272eb662 Add g_sequence_lookup{_iter} into symbols 2010-12-20 18:50:33 +01:00
Xavier Claessens
e666a2ed69 Add note in g_sequence_search() doc about g_sequence_lookup() 2010-12-20 17:30:58 +01:00
Xavier Claessens
50f96ae79b Add unit test for g_sequence_lookup() and g_sequence_lookup_iter(). 2010-12-20 17:30:58 +01:00
Xavier Claessens
4e30904331 New API: g_sequence_lookup() and g_sequence_lookup_iter()
Fixes bug #617254
2010-12-20 17:30:58 +01:00
Javier Jardón
f0354ff059 grand: Fix URLs for info on the Mersenne Twister
Reported by Allin Cottrell here:
http://mail.gnome.org/archives/gtk-devel-list/2010-December/msg00134.html
2010-12-17 16:12:16 +00:00
Dan Winship
7ee902a3d0 ghostutils: Convert non-ASCII dots to '.' when converting hostnames
Also add some test cases to test/hostutils for that and a few other
things, and make the test program just act as an ASCII/unicode
hostname converter rather than a test program if it's run with an
argument.

https://bugzilla.gnome.org/show_bug.cgi?id=633350
2010-12-15 03:56:35 -05:00
Christian Persch
ce50df7e0e Better error reporting for g_variant_parse()
Add error codes, and use them when setting the GError.

Bug #634583.
2010-12-12 13:25:34 +01:00
Chris Kühl
8530a3b029 Added note in g_slist_free about using *free_full to mirror GList docs 2010-12-06 00:34:59 +01:00
Matthias Clasen
b52294d14c Try to fix the version test on builders 2010-12-04 14:12:07 -05:00
Matthias Clasen
658572978b Reword awkward sentence in the docs
Pointed out in bug 636305, the docs for g_queue_remove_all() had
several grammatical errors and sounded awkward.
2010-12-03 14:45:09 -05:00
Matthias Clasen
99332dd27c Avoid shadowing dir builtin
This is the same change that was already applied to the other gdb
script we ship. I had forgotten there was a second one.
2010-12-03 14:41:06 -05:00
Colin Walters
05428e3c1a glib: Document g_string_free semantics better in the FALSE case 2010-12-03 10:37:28 -05:00
Benjamin Otte
889889a296 glib: Fix enumeration warnings from gcc 4.5
Just introduce more values for our private enum for the cases that were
missing.
2010-12-02 20:11:28 +01:00
Bastien Nocera
3e61cb2fcc Fix typo in API docs for GDateTime
s/monty/month/
2010-12-02 16:59:22 +00:00
Damien Lespiau
beec9743eb gmain: Add Since: 2.28 tag to g_source_{add,remove}_child_source
New API should have gtk-doc tags to document the version it was
introduced.

Signed-off-by: Javier Jardón <jjardon@gnome.org>
2010-12-01 01:12:32 +01:00
Matthias Clasen
02978fff17 Update NEWS 2010-11-29 01:16:02 -05:00
Christian Persch
d19e1a2c3c Use same variable names in .h and .c 2010-11-27 12:47:36 +01:00
Dan Winship
d15cdbefec gmain: add g_source_add_child_source and g_source_remove_child_source
This adds "child source" support to GSource. A child source behaves
basically like a GPollFD; when you add a source to a context, all of
its child sources are added with the same priority; when you destroy a
source, all of its child sources are destroyed; and when a child
source triggers, its parent source's dispatch function is run.

Use cases include:

    - adding a GTimeoutSource to another source to cause the source to
      automatically trigger after a certain timeout.

    - wrapping an existing source type with a new type that has
      a different callback signature

    - creating a source that triggers based on different conditions
      at different times.

https://bugzilla.gnome.org/show_bug.cgi?id=634239
2010-11-26 15:07:28 -05:00
Dan Winship
ece936e84d gmain: fix some silly code in a programmer-error case
Previously if a source got finalized while still attached to a
context, it would warn and re-ref the source. But then it just freed
it anyway... So keep the warning but drop the re-ref.

https://bugzilla.gnome.org/show_bug.cgi?id=634239
2010-11-26 15:07:28 -05:00
Dan Winship
b358202856 gmain: move finalization of GSource outside of context lock
This avoids ugly deadlock situations such as in
https://bugzilla.gnome.org/show_bug.cgi?id=586432

https://bugzilla.gnome.org/show_bug.cgi?id=626702

https://bugzilla.gnome.org/show_bug.cgi?id=634239
2010-11-26 15:07:28 -05:00
Owen W. Taylor
a70ba9c8b1 Fix off-by-1000 for GTimer
Divide monotonic time by 1e6 not 1e9 to get seconds.
2010-11-21 22:01:52 -05:00
Ryan Lortie
354d655ba8 g_str_hash: switch to using DJB hash
This is the same as what we were already doing with 2 changes:

  - use an initial value of 5381 instead of 0

  - multiply by 33 in each round instead of 31
2010-11-17 12:24:53 -05:00
Ryan Lortie
f50a99e782 g_str_hash: clean up code
Un-unroll the first iteration.

No functional changes here.
2010-11-17 12:24:53 -05:00
Chun-wei Fan
029f3070e7 gtimer.c: Revert accidental overwrite
Revert accidental overwrite as timing API was changed from 2.27.2 to 2.27.3
2010-11-09 20:32:39 +08:00
Chun-wei Fan
9806040455 Added and Moved checks for includes
Moved checks for G_OS_WIN32 after GLib header includes and added other checks
required for Windows/MSVC builds
2010-11-09 09:53:12 +08:00
Dan Winship
791d91a957 fix make check 2010-11-07 12:56:08 -05:00
Ryan Lortie
ba9fccf71e g_get_user_runtime_dir(): New function
Get the value of the XDG_RUNTIME_DIR environment variable.
2010-11-06 17:35:10 -04:00
Christian Persch
fa774618fc Fix docs comment typo 2010-11-06 12:27:01 +01:00
Ryan Lortie
7fc6f8a159 Add g_variant_lookup() and tests
Convenience API for doing lookups in dictionaries where the key is a
string or object path.
2010-11-05 21:33:43 -04:00
Tor Lillqvist
0940828418 Clarify docs for g_path_is_absolute() semantics on Windows 2010-11-04 22:18:42 +02:00
Ryan Lortie
e4ad3442c0 GMainContext: store real time as int64 2010-11-02 22:39:09 -04:00
Ryan Lortie
5dab4727ee Add g_get_real_time() for wall-clock int64 micros
Similar in spirit to g_get_monotonic_time().
2010-11-02 22:39:09 -04:00
Ryan Lortie
38e7aa9855 Clean up g_usleep()
Remove some code that was written in 2000 to support OSes that do not
have nanosleep().  nanosleep() has been specified (in POSIX-1.2001) for
almost a decade now, so assume we have it (except on Windows).

Remove the checks for nanosleep and nsleep from configure.ac.

We're removing this code because we honestly believe that nobody will be
affected.  If this change negatively impacts you, please file a bug.
2010-11-02 22:39:09 -04:00
Ryan Lortie
a48faa0aed GTimer: switch to monotonic time
and remove docs notes about threads having to be initialised.
2010-11-02 22:39:09 -04:00