X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=queue.c;h=a0ac72d282ea3ea6cb4e3fb2dbffa8e000347df6;hb=63352c7277aa5760cca113b9a97d09716ba4e7f8;hp=1435d5e09be0243a42f7f9646e5ec69b640ed04d;hpb=d96c455efaab3a585c3ba93a924856a4a6ee2ddb;p=ir-tcl-moved-to-github.git diff --git a/queue.c b/queue.c index 1435d5e..a0ac72d 100644 --- a/queue.c +++ b/queue.c @@ -6,7 +6,17 @@ * Sebastian Hammer, Adam Dickmeiss * * $Log: queue.c,v $ - * Revision 1.4 1995-10-17 12:18:59 adam + * Revision 1.7 1996-02-19 15:41:55 adam + * Better log messages. + * Minor improvement of connect method. + * + * Revision 1.6 1996/02/06 09:22:54 adam + * Ported ir-tcl to use beta releases of tcl7.5/tk4.1. + * + * Revision 1.5 1995/11/28 13:53:40 quinn + * Windows port. + * + * Revision 1.4 1995/10/17 12:18:59 adam * Bug fix: when target connection closed, the connection was not * properly reestablished. * @@ -36,7 +46,7 @@ int ir_tcl_send_APDU (Tcl_Interp *interp, IrTcl_Obj *p, Z_APDU *apdu, if (!z_APDU (p->odr_out, &apdu, 0)) { - Tcl_AppendResult (interp, odr_errlist [odr_geterror (p->odr_out)], + Tcl_AppendResult (interp, odr_errmsg (odr_geterror (p->odr_out)), NULL); odr_reset (p->odr_out); return TCL_ERROR; @@ -79,13 +89,18 @@ int ir_tcl_send_q (IrTcl_Obj *p, IrTcl_Request *rp, const char *msg) return TCL_ERROR; else if (r == 1) { +#if IRTCL_GENERIC_FILES + ir_select_add_write (p->csFile, p); +#else ir_select_add_write (cs_fileno (p->cs_link), p); +#endif logf (LOG_DEBUG, "Send part of %s", msg); p->state = IR_TCL_R_Writing; } else { - logf (LOG_DEBUG, "Send %s (%d bytes)", msg, rp->len_out); + logf (LOG_DEBUG, "Send %s (%d bytes) fd=%d", msg, rp->len_out, + cs_fileno(p->cs_link)); p->state = IR_TCL_R_Waiting; free (rp->buf_out); rp->buf_out = NULL;