@@ -602,10 +602,15 @@ break; } tmpDestinationLength = *destinationLength; chk_rv = moduleFunctionList->C_Sign(hSession, data, dataLength, destination, &tmpDestinationLength); + + if (tmpDestinationLength == 0) { + chk_rv = CKR_GENERAL_ERROR; + } + switch (chk_rv) { case CKR_OK: *destinationLength = tmpDestinationLength; retval = CACKEY_CHROME_OK; break;