projects
/
ir-tcl-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
16d63e7
)
Bug fix: ir_tcl_select_set called Tcl_GetFile at disconnect.
author
Adam Dickmeiss
<adam@indexdata.dk>
Fri, 13 Sep 1996 10:51:48 +0000
(10:51 +0000)
committer
Adam Dickmeiss
<adam@indexdata.dk>
Fri, 13 Sep 1996 10:51:48 +0000
(10:51 +0000)
ir-tcl.c
patch
|
blob
|
history
select.c
patch
|
blob
|
history
diff --git
a/ir-tcl.c
b/ir-tcl.c
index
78aacca
..
cbf0d76
100644
(file)
--- a/
ir-tcl.c
+++ b/
ir-tcl.c
@@
-5,7
+5,10
@@
* Sebastian Hammer, Adam Dickmeiss
*
* $Log: ir-tcl.c,v $
* Sebastian Hammer, Adam Dickmeiss
*
* $Log: ir-tcl.c,v $
- * Revision 1.94 1996-08-21 13:32:53 adam
+ * Revision 1.95 1996-09-13 10:51:49 adam
+ * Bug fix: ir_tcl_select_set called Tcl_GetFile at disconnect.
+ *
+ * Revision 1.94 1996/08/21 13:32:53 adam
* Implemented saveFile method and extended loadFile method to work with it.
*
* Revision 1.93 1996/08/16 15:07:45 adam
* Implemented saveFile method and extended loadFile method to work with it.
*
* Revision 1.93 1996/08/16 15:07:45 adam
@@
-1161,12
+1164,11
@@
void ir_tcl_disconnect (IrTcl_Obj *p)
logf(LOG_DEBUG, "Closing connection to %s", p->hostname);
xfree (p->hostname);
p->hostname = NULL;
logf(LOG_DEBUG, "Closing connection to %s", p->hostname);
xfree (p->hostname);
p->hostname = NULL;
- ir_select_remove_write (cs_fileno (p->cs_link), p);
+ assert (p->cs_link);
ir_select_remove (cs_fileno (p->cs_link), p);
odr_reset (p->odr_in);
ir_select_remove (cs_fileno (p->cs_link), p);
odr_reset (p->odr_in);
- assert (p->cs_link);
cs_close (p->cs_link);
p->cs_link = NULL;
cs_close (p->cs_link);
p->cs_link = NULL;
diff --git
a/select.c
b/select.c
index
93f2012
..
dde83a3
100644
(file)
--- a/
select.c
+++ b/
select.c
@@
-5,7
+5,10
@@
* Sebastian Hammer, Adam Dickmeiss
*
* $Log: select.c,v $
* Sebastian Hammer, Adam Dickmeiss
*
* $Log: select.c,v $
- * Revision 1.1 1996-08-20 09:33:23 adam
+ * Revision 1.2 1996-09-13 10:51:48 adam
+ * Bug fix: ir_tcl_select_set called Tcl_GetFile at disconnect.
+ *
+ * Revision 1.1 1996/08/20 09:33:23 adam
* Tcl7.5 Generic file handling.
*
*/
* Tcl7.5 Generic file handling.
*
*/
@@
-67,6
+70,8
@@
void ir_tcl_select_set (void (*f)(ClientData clientData, int r, int w, int e),
}
if (!*sp)
{
}
if (!*sp)
{
+ if (!f)
+ return;
*sp = ir_tcl_malloc (sizeof(**sp));
(*sp)->next = NULL;
(*sp)->fd = fd;
*sp = ir_tcl_malloc (sizeof(**sp));
(*sp)->next = NULL;
(*sp)->fd = fd;
@@
-116,6
+121,8
@@
void ir_tcl_select_set (void (*f)(ClientData clientData, int r, int w, int e),
}
if (!sp)
{
}
if (!sp)
{
+ if (!f)
+ return;
sp = ir_tcl_malloc (sizeof(*sp));
sp->next = sel_proc_list;
sel_proc_list = sp;
sp = ir_tcl_malloc (sizeof(*sp));
sp->next = sel_proc_list;
sel_proc_list = sp;