[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [pkcs11] Define constants for (CK_ULONG)-1
On 11.05.2013 00:30, Michael StJohns wrote: > On 5/10/2013 8:31 AM, Stef Walter wrote: > As discussed earlier on the mailing list, following are the > modifications to the specification to be made in order to define > constants for (CK_ULONG)-1. > >> I went back and took a look at the source documents. The only place >> that this is used is as a return value of attribute length in >> C_GetAttributeValue to indicate which of the attributes are invalid. (I >> searched for '-1' and the only place I found it - other than SHA-1 and >> length-1 type constructs - was there). > >> So how about only CKL_INVALID_ATTRIBUTE = -1; > There are several kinds of dashes/hyphens used in a '-1' construct in the document. See my edits below for all appropriate locations of -1 cast to CK_ULONG. ... snip > In line with Peter's suggestion, three new constants are defined: > > CKA_INVALID > CKM_INVALID > CK_INVALID_LENGTH In addition to their uses in the document. CKA_INVALID and CKM_INVALID are useful when writing code. Many (most ?) of us have defined them. This is similar to CK_INVALID_HANDLE which is not used in the document. Cheers, Stef
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]