Commit Graph

22289 Commits

Author SHA1 Message Date
Patrick Griffis
8b319a687b guri: Fix user passed to g_uri_split_with_user() not being NULL'd 2020-09-02 15:43:58 -05:00
Philip Withnall
47488cc1a0 2.65.3
Signed-off-by: Philip Withnall <withnall@endlessm.com>
2020-09-02 16:48:52 +01:00
Sebastian Dröge
054ef4ddf7 Merge branch '2191-scheduler-warnings' into 'master'
gthread: Only print scheduler setting warnings once

Closes #2191

See merge request GNOME/glib!1637
2020-09-02 15:28:17 +00:00
Philip Withnall
c8840ff9a8 gthread: Only print scheduler setting warnings once
If one thread pool thread fails to set its scheduler settings, it’s
likely that all the rest of them will fail for the same reason. Avoid
printing duplicate critical warnings in that case.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Fixes: #2191
2020-09-02 16:09:12 +01:00
Philip Withnall
eba91d5c87 Merge branch 'big_O_notations' into 'master'
Big o notations

See merge request GNOME/glib!1025
2020-09-02 13:09:52 +00:00
Emmanuel Fleury
d27549b0f4 Add some notes on complexity in glib/gtree.c
Related to issue #3
2020-09-02 14:38:15 +02:00
Emmanuel Fleury
54c20c8532 Add some notes on complexity in glib/gsequence.c
Related to issue #3
2020-09-02 14:38:15 +02:00
Emmanuel Fleury
a62fcb9af1 Add some notes on complexity in glib/gqueue.c
Related to issue #3
2020-09-02 14:38:15 +02:00
Emmanuel Fleury
69e5e12c95 Add some notes on complexity in glib/gslist.c
Related to issue #3
2020-09-02 14:38:15 +02:00
Emmanuel Fleury
4d9cd832d1 Add some notes on complexity in glib/glist.c
Related to issue #3
2020-09-02 14:38:15 +02:00
Emmanuel Fleury
cbae555a98 Add some notes on complexity in glib/ghash.c
Related to issue #3
2020-09-02 14:38:10 +02:00
Emmanuel Fleury
34f03f01c8 Add some notes on complexity in glib/garray.c
Related to issue #3
2020-09-02 14:36:22 +02:00
Sebastian Dröge
b01bcd38a6 Merge branch '2197-option-group-limits' into 'master'
goption: Add a precondition to avoid GOptionEntry list overflow

Closes #2197

See merge request GNOME/glib!1638
2020-09-02 11:58:31 +00:00
Philip Withnall
63c5b62f0a goption: Add a precondition to avoid GOptionEntry list overflow
If the calling code adds more option entries than `G_MAXSIZE` then
there’ll be an integer overflow. This seems vanishingly unlikely (given
that all callers use static option entry lists), but add a precondition
anyway.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Fixes: #2197
2020-09-02 12:48:37 +01:00
Mario Blättermann
14d9cde59e Update German translation 2020-09-02 11:31:42 +00:00
Simon McVittie
bdcf193c2e Merge branch 'cancellable-disable-assert' into 'master'
gcancellable: Mark a variable as unused if built with G_DISABLE_ASSERT

See merge request GNOME/glib!1635
2020-09-01 13:55:48 +00:00
Fabio Tomat
489941242e Update Friulian translation 2020-09-01 13:40:50 +00:00
Philip Withnall
30a31b21fb gcancellable: Mark a variable as unused if built with G_DISABLE_ASSERT
It’s only used in an assertion. This fixes a compiler warning.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2020-09-01 12:23:19 +01:00
Fabio Tomat
7ae9b768ee Update Friulian translation 2020-09-01 09:56:38 +00:00
Matej Urbančič
a81817085c Updated Slovenian translation 2020-08-31 21:48:33 +02:00
Bruce Cowan
43656b594b Update British English translation 2020-08-30 11:23:21 +00:00
Changwoo Ryu
4e00765bf1 Update Korean translation 2020-08-30 07:46:55 +00:00
Boyuan Yang
51d8d72425 Update Chinese (China) translation 2020-08-30 00:47:11 +00:00
Marek Černocký
a75b8789ea Updated Czech translation 2020-08-28 20:13:34 +02:00
Marek Černocký
1c5073e27a Updated Czech translation 2020-08-28 20:11:29 +02:00
Asier Sarasua Garmendia
e6791aa22a Update Basque translation 2020-08-28 10:39:25 +00:00
Sebastian Dröge
e5c119ea41 Merge branch 'wip/carlosg/cancelled-splice' into 'master'
Fix splice behavior on cancellation

See merge request GNOME/glib!1631
2020-08-28 10:04:47 +00:00
Carlos Garnacho
cf85241aba tests: Add splice cancellation test
This doesn't trigger the cancellation assertion issue when run locally
(the task didn't return yet, so the error is simply overwritten), but
perhaps it ever does in CI. Anyhow, it's good to have a cancellation
test.
2020-08-28 11:38:51 +02:00
Carlos Garnacho
c033450f93 goutputstream: Check individual close operations after splice
After a splice operation is finished, it attempts to 1) close input/output
streams, as per the given flags, and 2) return the operation result (maybe
an error, too).

However, if the operation gets cancelled early and the streams indirectly
closed, the splice operation will try to close both descriptors and return
on the task when both are already closed. The catch here is that getting the
streams closed under its feet is possible, so the completion callback would
find both streams closed after returning on the first close operation and
return the error, but then the second operation could be able to trigger
a second error which would be returned as well.

What happens here is up to further race conditions, if the task didn't
return yet, the returned error will be simply replaced (but the old one not
freed...), if it did already return, it'll result in:

GLib-GIO-FATAL-CRITICAL: g_task_return_error: assertion '!task->ever_returned' failed

Fix this by flagging the close_async() callbacks, and checking that both
close operations did return, instead of checking that both streams are
closed by who knows.

This error triggers a semi-frequent CI failure in tracker, see the summary at
https://gitlab.gnome.org/GNOME/tracker/-/issues/240
2020-08-28 11:22:14 +02:00
Sebastian Dröge
151e171207 Merge branch 'gfileutils_signedness' into 'master'
Fixing signedness warning in glib/gfileutils.c

See merge request GNOME/glib!1632
2020-08-27 16:50:37 +00:00
Sebastian Dröge
dae128e6bb Don't pass more than G_MAXSSIZE bytes at once to write() in glib/gfileutils.c
Behaviour in that case is implementation-defined and how many bytes were
actually written can't be expressed by the return value anymore.

Instead do a short write of G_MAXSSIZE bytes and let the existing loop
for handling short writes takes care of the remaining length.
2020-08-27 19:32:14 +03:00
Emmanuel Fleury
856265fe66 Fixing signedness warning in glib/gfileutils.c
glib/gfileutils.c: In function ‘write_to_file’:
glib/gfileutils.c:1176:19: error: comparison of integer expressions of different signedness: ‘gssize’ {aka ‘long int’} and ‘gsize’ {aka ‘long unsigned int’} [-Werror=sign-compare]
 1176 |       g_assert (s <= length);
      |                   ^~
glib/gmacros.h:939:25: note: in definition of macro ‘G_LIKELY’
  939 | #define G_LIKELY(expr) (expr)
      |                         ^~~~
glib/gfileutils.c:1176:7: note: in expansion of macro ‘g_assert’
 1176 |       g_assert (s <= length);
      |       ^~~~~~~~

Related to issue #1735 (Get back to a -werror build)
2020-08-27 19:32:11 +03:00
Aurimas Černius
0d196a99b5 Updated Lithuanian translation 2020-08-26 22:36:28 +03:00
Philip Withnall
9674d14175 Merge branch 'g_settings_new' into 'master'
gio: Document g_settings_new() missing schema behaviour

See merge request GNOME/glib!1626
2020-08-24 09:02:43 +00:00
Chris Mayo
dc1a1b841c gio: Document g_settings_new() missing schema behaviour
Explain what happens, the rationale and reference another
function that may be helpful.
2020-08-24 09:02:43 +00:00
Sebastian Dröge
e47a7e297c Merge branch 'valentindavid/statx-read-only' into 'master'
gio: Allow no atime from statx

Closes #2189

See merge request GNOME/glib!1630
2020-08-24 08:54:13 +00:00
Valentin David
6fc143bba8
gio: Allow no atime from statx
statx does not provide stx_atime when querying a file in a read-only
mounted file system. So call to statx should not expect it to be in
the mask. Otherwise we would fail with ERANGE for querying any file in
a read-only file system.

Fixes #2189.
2020-08-23 16:41:17 +02:00
Jordi Mas
c0435cd722 Update Catalan translation 2020-08-23 09:00:56 +02:00
Piotr Drąg
b3c0dd27be Update Polish translation 2020-08-22 15:29:41 +02:00
Philip Withnall
153ec62e7e Merge branch 'wip/baedert/fallthrough' into 'master'
Replace a bunch of fallthrough comments with an attribute

See merge request GNOME/glib!1628
2020-08-21 08:49:11 +00:00
Philip Withnall
a1a8016553 Merge branch 'thread-trace' into 'master'
gthread: Add a sysprof mark for thread creation

See merge request GNOME/glib!1627
2020-08-21 08:39:12 +00:00
Timm Bäder
aeed676c08 Replace a bunch of fallthrough comments with an attribute
Parsing comments is hack and clang doesn't do it, so switch to
G_GNUC_FALLTHROUGH, which exists for exactly this case.
2020-08-21 05:50:02 +02:00
Matthias Clasen
5620828f47 gthread: Add a sysprof mark for thread creation
sysprof already shows forks in the waterfall. The
main benefit of adding a mark is that it makes the
thread name show up in the trace, next to the fork.
2020-08-20 15:23:05 -04:00
sicklylife
46a12eaf23 Update Japanese translation 2020-08-20 12:07:56 +00:00
sicklylife
d2803e11ba Update Japanese translation 2020-08-20 11:51:20 +00:00
sicklylife
5725415ac6 Update Japanese translation 2020-08-20 11:33:21 +00:00
Rafael Fontenelle
684e68365d Update Brazilian Portuguese translation 2020-08-20 11:18:58 +00:00
Baurzhan Muftakhidinov
f95723a587 Update Kazakh translation 2020-08-19 09:41:25 +00:00
Philip Withnall
f91af2021c 2.65.2
Signed-off-by: Philip Withnall <withnall@endlessm.com>
2020-08-18 11:49:43 +01:00
Sebastian Dröge
24af98e0ee Merge branch 'cancellable-pollfd' into 'master'
gcancellable: Assert that make_pollfd() call succeeds

See merge request GNOME/glib!1623
2020-08-18 10:35:16 +00:00