Work on target definitions.
[egate.git] / www / wirtcl.c
index 9939df8..c0ae80e 100644 (file)
  * USE OR PERFORMANCE OF THIS SOFTWARE.
  *
  * $Log: wirtcl.c,v $
- * Revision 1.9  1995/11/07 14:56:59  adam
+ * Revision 1.13  1996/01/24 08:26:54  adam
+ * All tcl commands prefixed with egw_ (except the html command).
+ *
+ * Revision 1.12  1996/01/12  10:05:18  adam
+ * If script name ends with ';' HTTP/GET/Expires will be defined.
+ * The cgi interface only reads final handshake if response from
+ * server (shell) was zero-terminated [If it isn't it probably died].
+ *
+ * Revision 1.11  1996/01/09  16:16:49  adam
+ * Port to OSF/1. Gif references moved from /gif/ to /egwgif/.
+ *
+ * Revision 1.10  1996/01/09  10:46:50  adam
+ * New defines: LOGDIR/EGWDIR/CGIDIR set in Makefile.
+ *
+ * Revision 1.9  1995/11/07  14:56:59  adam
  * Work on search in multiple targets.
  * New wtcl command: wlog.
  * Optional timeout parameter to zwait.
@@ -166,9 +180,9 @@ static void *do_create (WCLIENT wcl, void *args)
         gw_log (GW_LOG_FATAL, mod, "Cannot make Irtcl_Interp");
         exit (1);
     }
-    log_init(LOG_ALL, "irtcl", "/usr/local/etc/httpd/logs/irtcl_log");
+    log_init(LOG_ALL, "irtcl", LOGDIR "/irtcl_log");
     /* initialize irtcl */
-    Tcl_CreateCommand (p->interp, "zwait", proc_zwait_invoke, p, NULL);
+    Tcl_CreateCommand (p->interp, "egw_wait", proc_zwait_invoke, p, NULL);
     for (i=0; i<MAX_CALLBACK; i++)
     {
         callback_table[i].r_handle = NULL;
@@ -287,18 +301,18 @@ static int events (struct tcl_info *p, char *waitVar, int tout)
         {
             if (FD_ISSET (i, &fdset_tcl_r))
             {
-                assert (callback_table[i].r_handle);
-                (*callback_table[i].r_handle) (callback_table[i].obj);
+                if (callback_table[i].r_handle)
+                    (*callback_table[i].r_handle) (callback_table[i].obj);
             }
             if (FD_ISSET (i, &fdset_tcl_w))
             {
-                assert (callback_table[i].w_handle);
-                (*callback_table[i].w_handle) (callback_table[i].obj);
+                if (callback_table[i].w_handle)
+                    (*callback_table[i].w_handle) (callback_table[i].obj);
             }
             if (FD_ISSET (i, &fdset_tcl_x))
             {
-                assert (callback_table[i].x_handle);
-                (*callback_table[i].x_handle) (callback_table[i].obj);
+                if (callback_table[i].x_handle)
+                    (*callback_table[i].x_handle) (callback_table[i].obj);
             }
         }
     }