From: Adam Dickmeiss Date: Wed, 24 Jan 1996 08:26:54 +0000 (+0000) Subject: All tcl commands prefixed with egw_ (except the html command). X-Git-Url: http://sru.miketaylor.org.uk/?a=commitdiff_plain;h=3b5ea708cd1a08f4ca78f256bc508086967ec58d;hp=95847d2bfe19cbe5533cd25df3e6a64f9bd4b062;p=egate.git All tcl commands prefixed with egw_ (except the html command). --- diff --git a/www/wirtcl.c b/www/wirtcl.c index 4828b89..c0ae80e 100644 --- a/www/wirtcl.c +++ b/www/wirtcl.c @@ -41,7 +41,10 @@ * USE OR PERFORMANCE OF THIS SOFTWARE. * * $Log: wirtcl.c,v $ - * Revision 1.12 1996/01/12 10:05:18 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]. @@ -179,7 +182,7 @@ static void *do_create (WCLIENT wcl, void *args) } 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; iwcl, argv[i]); + wo_write (p->wcl, argv[i], strlen(argv[i])); return TCL_OK; } -static int proc_htmlr_invoke (ClientData clientData, Tcl_Interp *interp, - int argc, char **argv) -{ - struct tcl_info *p = (struct tcl_info*) clientData; - int r; - - r = proc_html_invoke (clientData, interp, argc, argv); - wo_putc (p->wcl, '\n'); - return r; -} - static int proc_wform_invoke (ClientData clientData, Tcl_Interp *interp, int argc, char **argv) { @@ -261,11 +253,10 @@ static void *do_create (WCLIENT wcl, void *args) } Tcl_AppInit (p->interp); Tcl_CreateCommand (p->interp, "html", proc_html_invoke, p, NULL); - Tcl_CreateCommand (p->interp, "htmlr", proc_htmlr_invoke, p, NULL); - Tcl_CreateCommand (p->interp, "wform", proc_wform_invoke, p, NULL); - Tcl_CreateCommand (p->interp, "wabort", proc_wabort_invoke, p, NULL); - Tcl_CreateCommand (p->interp, "wflush", proc_wflush_invoke, p, NULL); - Tcl_CreateCommand (p->interp, "wlog", proc_wlog_invoke, p, NULL); + Tcl_CreateCommand (p->interp, "egw_form", proc_wform_invoke, p, NULL); + Tcl_CreateCommand (p->interp, "egw_abort", proc_wabort_invoke, p, NULL); + Tcl_CreateCommand (p->interp, "egw_flush", proc_wflush_invoke, p, NULL); + Tcl_CreateCommand (p->interp, "egw_log", proc_wlog_invoke, p, NULL); sprintf (tmp_str, "%d", wcl->id); Tcl_SetVar (p->interp, "sessionId", tmp_str, TCL_GLOBAL_ONLY); return p; @@ -405,9 +396,7 @@ static int do_load (char *parms, void *mydata) sprintf (fname, "tcl.state.%d", p->wcl->id); r = Tcl_EvalFile (p->interp, fname); if (r == TCL_ERROR) - report_error (p, p->interp->errorLine, - "Error in Tcl loadState in line", - Tcl_GetVar (p->interp, "errorInfo", 0)); + gw_log (GW_LOG_WARN, mod, "Cannot load Tcl state" ); return 0; }