Changeset 269 for trunk/src/tools/pkcs11_eventmgr.c
- Timestamp:
- 05/15/07 07:18:24 (5 years ago)
- File:
-
- 1 edited
-
trunk/src/tools/pkcs11_eventmgr.c (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/tools/pkcs11_eventmgr.c
r243 r269 74 74 void *module_handle; 75 75 CK_FUNCTION_LIST_PTR fl; 76 int should_finalize; 76 77 slot_t *slots; 77 78 CK_ULONG slot_count; … … 510 511 } 511 512 512 /* open pkcs11 sesion */513 DBG("initialising pkcs #11 module...");514 rv = ph->fl->C_Initialize(NULL);515 if (rv != 0) {516 release_pkcs11_module(ph);517 DBG1("C_Initialize() failed: %d", rv);518 return 1;519 }520 521 513 /* put my self into background if flag is set */ 522 514 if (daemonize) { … … 529 521 } 530 522 } 523 524 /* open pkcs11 sesion */ 525 DBG("initialising pkcs #11 module..."); 526 rv = ph->fl->C_Initialize(NULL); 527 if (rv != 0) { 528 release_pkcs11_module(ph); 529 if (ctx) 530 scconf_free(ctx); 531 DBG1("C_Initialize() failed: %d", rv); 532 return 1; 533 } 534 ph->should_finalize = 1; 531 535 532 536 /* … … 551 555 if (new_state == CARD_ERROR) { 552 556 DBG("Error trying to get a token"); 557 rv = ph->fl->C_Finalize(NULL); 558 rv = ph->fl->C_Initialize(NULL); 553 559 break; 554 560 }
Note: See TracChangeset
for help on using the changeset viewer.
