From 619923025be6f40e56514673203aa07184c18339 Mon Sep 17 00:00:00 2001 From: Stef Walter Date: Sun, 11 Jul 2010 23:17:20 +0000 Subject: [PATCH] [gp11] Open readonly sessions when enumerating objects. * This is an interim measure. When GP11 is redone the API should allow the caller to specify this. --- gp11/gp11-module.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gp11/gp11-module.c b/gp11/gp11-module.c index ac1d619..7255724 100644 --- a/gp11/gp11-module.c +++ b/gp11/gp11-module.c @@ -1167,7 +1167,9 @@ gp11_module_enumerate_objects_full (GP11Module *self, GP11Attributes *attrs, slots = gp11_module_get_slots (self, TRUE); for (l = slots; ret && !stop && l; l = g_list_next (l)) { - session = gp11_slot_open_session (l->data, CKF_SERIAL_SESSION, &error); + + /* TODO: We really should allow the caller to specify the flags, at least read-write */ + session = gp11_slot_open_session (l->data, CKF_RW_SESSION | CKF_SERIAL_SESSION, &error); if (!session) { g_return_val_if_fail (error != NULL, FALSE); -- 2.7.4