[gnome-keyring] pkcs11: Fix deprecated use of g_atomic_int_exchange_and_add()
- From: Stefan Walter <stefw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-keyring] pkcs11: Fix deprecated use of g_atomic_int_exchange_and_add()
- Date: Wed, 6 Jul 2011 14:42:22 +0000 (UTC)
commit e75e8bc13f6568186b9f9fb05d9ad30ac3e95e59
Author: Stef Walter <stefw collabora co uk>
Date: Wed Jul 6 16:41:05 2011 +0200
pkcs11: Fix deprecated use of g_atomic_int_exchange_and_add()
pkcs11/gkm/gkm-util.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/pkcs11/gkm/gkm-util.c b/pkcs11/gkm/gkm-util.c
index 37561d9..f8de836 100644
--- a/pkcs11/gkm/gkm-util.c
+++ b/pkcs11/gkm/gkm-util.c
@@ -125,7 +125,11 @@ gkm_util_return_data (CK_VOID_PTR output, CK_ULONG_PTR n_output,
CK_ULONG
gkm_util_next_handle (void)
{
+#if GLIB_CHECK_VERSION(2,29,6)
+ return (CK_ULONG)g_atomic_int_add (&next_handle, 1);
+#else
return (CK_ULONG)g_atomic_int_exchange_and_add (&next_handle, 1);
+#endif
}
void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]