On Mon, 9 Aug 2010 11:42:04 -0500 Kent Yoder <[email protected]> wrote:
> - fix compile warnings generated by -Wall > - always return a non-zero error code to the command line on test error > - use a macro to send output to stderr when appropriate > - print file/line numbers for any failures > > Signed-off-by: Kent Yoder <[email protected]> > > testcases/driver/sess_perf.c | 23 ++++++++++++----------- > 1 files changed, 12 insertions(+), 11 deletions(-) > > diff --git a/testcases/driver/sess_perf.c b/testcases/driver/sess_perf.c > index c103418..930de21 100755 > --- a/testcases/driver/sess_perf.c > +++ b/testcases/driver/sess_perf.c > @@ -12,8 +12,8 @@ > #include "regress.h" > > #define DATALEN 1024 > -char DATA[DATALEN]; > -char DUMP[DATALEN]; > +CK_BYTE DATA[DATALEN]; > +CK_BYTE DUMP[DATALEN]; > > typedef struct _context_table { > CK_SESSION_HANDLE hsess; > @@ -97,7 +97,8 @@ int encrypt_DATA(CK_SESSION_HANDLE hsess, CK_OBJECT_HANDLE > hkey, CK_ULONG blockl > unsigned long int i; > > for (i = 0; i < DATALEN; i+=outlen) { > - rc = funcs->C_EncryptUpdate(hsess, (DATA + i) , blocklen, (DUMP > + i), &outlen); > + rc = funcs->C_EncryptUpdate(hsess, (CK_BYTE_PTR)(DATA + i) , > blocklen, > + (CK_BYTE_PTR)(DUMP + i), &outlen); > if (rc != CKR_OK) { > show_error(" C_Encrypt #1", rc); > return FALSE; > @@ -153,13 +154,13 @@ int do_SessionPerformance(unsigned int count) > context_table_t *t = NULL; > > if (count == 0) { > - show_error(" do_SessionPerformance: zero session count", 0); > + show_error(" do_SessionPerformance: zero session count", > (CK_RV)0); Those (and the following ones) seems to be closer to PRINT_ERR() (no CK_RV matching) than show_error() right? -Klaus -- Klaus Heinrich Kiwi | [email protected] | http://blog.klauskiwi.com Open Source Security blog : http://www.ratliff.net/blog IBM Linux Technology Center : http://www.ibm.com/linux/ltc ------------------------------------------------------------------------------ This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev _______________________________________________ Opencryptoki-tech mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/opencryptoki-tech
