diff options
Diffstat (limited to 'security/policykit/patches/patch-authdb')
-rw-r--r-- | security/policykit/patches/patch-authdb | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/security/policykit/patches/patch-authdb b/security/policykit/patches/patch-authdb new file mode 100644 index 00000000000..ed466d35c3e --- /dev/null +++ b/security/policykit/patches/patch-authdb @@ -0,0 +1,25 @@ +$NetBSD: patch-authdb,v 1.1 2008/12/15 15:06:43 rillig Exp $ + +A uid isn't necessarily as large as a pointer, therefore gcc warns about +that cast. + +--- src/polkit/polkit-authorization-db.c.orig 2008-05-30 23:24:44.000000000 +0200 ++++ src/polkit/polkit-authorization-db.c 2008-12-15 13:58:52.000000000 +0100 +@@ -289,7 +289,7 @@ _authdb_get_auths_for_uid (PolKitAuthori + + /* first, see if this is in the cache */ + if (authdb->uid_to_authlist != NULL) { +- ret = kit_hash_lookup (authdb->uid_to_authlist, (void *) uid, NULL); ++ ret = kit_hash_lookup (authdb->uid_to_authlist, (void *) (ssize_t) uid, NULL); + if (ret != NULL) + goto out; + } +@@ -424,7 +424,7 @@ _authdb_get_auths_for_uid (PolKitAuthori + } + + if (authdb->uid_to_authlist == NULL || +- !kit_hash_insert (authdb->uid_to_authlist, (void *) uid, ret)) { ++ !kit_hash_insert (authdb->uid_to_authlist, (void *) (ssize_t) uid, ret)) { + polkit_error_set_error (error, + POLKIT_ERROR_OUT_OF_MEMORY, + "No memory"); |