You are viewing a plain text version of this content. The canonical link for it is here.
Posted to websh-cvs@tcl.apache.org by ro...@apache.org on 2002/04/05 11:18:52 UTC

cvs commit: tcl-websh/src/generic modwebsh_cgi.c

ronnie      02/04/05 01:18:52

  Modified:    src/generic modwebsh_cgi.c
  Log:
  - proper error handling in dummy procs (web::initializer and web::finalizer)
  
  Revision  Changes    Path
  1.4       +9 -5      tcl-websh/src/generic/modwebsh_cgi.c
  
  Index: modwebsh_cgi.c
  ===================================================================
  RCS file: /home/cvs/tcl-websh/src/generic/modwebsh_cgi.c,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- modwebsh_cgi.c	25 Oct 2001 17:50:13 -0000	1.3
  +++ modwebsh_cgi.c	5 Apr 2002 09:18:52 -0000	1.4
  @@ -9,7 +9,7 @@
    * See the file "license.terms" for information on usage and
    * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
    *
  - * @(#) $Id: modwebsh_cgi.c,v 1.3 2001/10/25 17:50:13 davidw Exp $
  + * @(#) $Id: modwebsh_cgi.c,v 1.4 2002/04/05 09:18:52 ronnie Exp $
    *
    */
   
  @@ -24,8 +24,10 @@
   
       int res = 0;
   
  -    if (objc != 2)
  -	return TCL_ERROR;
  +    if (objc != 2) {
  +      Tcl_WrongNumArgs(interp, 1, objv, "code");
  +      return TCL_ERROR;
  +    }
   
       Tcl_IncrRefCount(objv[1]);
       res = Tcl_EvalObjEx(interp, objv[1], 0);
  @@ -43,8 +45,10 @@
   
       int res = 0;
   
  -    if (objc != 2)
  -	return TCL_ERROR;
  +    if (objc != 2) {
  +      Tcl_WrongNumArgs(interp, 1, objv, "code");
  +      return TCL_ERROR;
  +    }
   
       Tcl_IncrRefCount(objv[1]);
       res = Tcl_EvalObjEx(interp, objv[1], 0);
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: websh-cvs-unsubscribe@tcl.apache.org
For additional commands, e-mail: websh-cvs-help@tcl.apache.org