* Copyright (c) 1995-2003, Index Data
* See the file LICENSE for details.
*
- * $Id: client.c,v 1.217 2003-12-22 19:46:22 adam Exp $
+ * $Id: client.c,v 1.219 2003-12-31 00:14:00 adam Exp $
*/
#include <stdio.h>
char *buf_out;
int len_out;
int r;
- if (apdu_file && !z_GDU(print, &gdu, 0, 0))
- printf ("Failed to print outgoing APDU\n");
+ if (apdu_file)
+ {
+ if (!z_GDU(print, &gdu, 0, 0))
+ printf ("Failed to print outgoing APDU\n");
+ odr_reset(print);
+ }
buf_out = odr_getbuf(out, &len_out, 0);
/* we don't odr_reset(out), since we may need the buffer again */
send_srw(sr);
return 2;
}
-#else
- return 0;
#endif
+ return 0;
}
static int cmd_find(const char *arg)
odr_dumpBER(f, netbuffer, res);
fprintf(f, "---------\n");
if (apdu_file)
+ {
z_GDU(print, &gdu, 0, 0);
+ odr_reset(print);
+ }
if (conn && cs_more(conn))
continue;
break;