[gnome-keyring/gnome-2-32] [rpc-layer] Fix invalid memory access.
- From: Stefan Walter <stefw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-keyring/gnome-2-32] [rpc-layer] Fix invalid memory access.
- Date: Fri, 1 Oct 2010 01:02:06 +0000 (UTC)
commit 58240b9acdd6ad54d8c6d4e8a668686a142258e4
Author: Stef Walter <stef memberwebs com>
Date: Fri Oct 1 01:01:04 2010 +0000
[rpc-layer] Fix invalid memory access.
Fix invalid memory access in gkm_rpc_mechanism_list_purge().
Pointed out by Tim Hudson.
pkcs11/rpc-layer/gkm-rpc-util.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/pkcs11/rpc-layer/gkm-rpc-util.c b/pkcs11/rpc-layer/gkm-rpc-util.c
index 42e16f7..725cc13 100644
--- a/pkcs11/rpc-layer/gkm-rpc-util.c
+++ b/pkcs11/rpc-layer/gkm-rpc-util.c
@@ -79,7 +79,7 @@ gkm_rpc_mechanism_list_purge (CK_MECHANISM_TYPE_PTR mechs, CK_ULONG* n_mechs)
assert (mechs);
assert (n_mechs);
- for (i = 0; i < (int)(*mechs); ++i) {
+ for (i = 0; i < (int)(*n_mechs); ++i) {
if (!gkm_rpc_mechanism_has_no_parameters (mechs[i]) &&
!gkm_rpc_mechanism_has_sane_parameters (mechs[i])) {
@@ -204,4 +204,4 @@ gkm_rpc_mechanism_has_no_parameters (CK_MECHANISM_TYPE mech)
default:
return 0;
};
-}
\ No newline at end of file
+}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]