1
commit 3b135a8d49a3b10b6b6ac050cfd457fa027f8b73
2
Author: Martin Pitt <martinpitt@gnome.org>
3
Date: Wed Sep 5 18:29:21 2012 +0200
5
Add workaround annotation for udisks_client_get_block_for_dev()
7
The gobject-introspection parser does not know how to properly handle dev_t
8
arguments (https://bugzilla.gnome.org/show_bug.cgi?id=584517) and treats them
9
as gint. But as the native API expects a 64 bit integer, you'll get garbage in
10
the upper word on 32 bit platforms, which cause
11
UDisks.Block.get_block_for_dev() to never find a match when using through
14
https://bugs.freedesktop.org/show_bug.cgi?id=54566
16
diff --git a/udisks/udisksclient.c b/udisks/udisksclient.c
17
index 17d0914..9981a93 100644
18
--- a/udisks/udisksclient.c
19
+++ b/udisks/udisksclient.c
20
@@ -640,10 +640,13 @@ udisks_client_get_block_for_uuid (UDisksClient *client,
22
/* ---------------------------------------------------------------------------------------------------- */
24
+/* Note: The (type guint64) is a workaround for g-i mishandling dev_t, see
25
+ * https://bugzilla.gnome.org/show_bug.cgi?id=584517 */
28
* udisks_client_get_block_for_dev:
29
* @client: A #UDisksClient.
30
- * @block_device_number: A #dev_t to get a #UDisksBlock for.
31
+ * @block_device_number: (type guint64): A #dev_t to get a #UDisksBlock for.
33
* Gets the #UDisksBlock corresponding to @block_device_number, if any.