svn commit: samba r8631 - in branches/SAMBA_4_0/source/lib/appweb: ejs esp

tridge at samba.org tridge at samba.org
Wed Jul 20 05:40:25 GMT 2005


Author: tridge
Date: 2005-07-20 05:40:24 +0000 (Wed, 20 Jul 2005)
New Revision: 8631

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=8631

Log:
give an error on incorrect argument count

Modified:
   branches/SAMBA_4_0/source/lib/appweb/ejs/ejsParser.c
   branches/SAMBA_4_0/source/lib/appweb/esp/esp.h


Changeset:
Modified: branches/SAMBA_4_0/source/lib/appweb/ejs/ejsParser.c
===================================================================
--- branches/SAMBA_4_0/source/lib/appweb/ejs/ejsParser.c	2005-07-20 05:13:01 UTC (rev 8630)
+++ branches/SAMBA_4_0/source/lib/appweb/ejs/ejsParser.c	2005-07-20 05:40:24 UTC (rev 8631)
@@ -2059,12 +2059,11 @@
 		formalArgs = prototype->function.args;
 		argNames = (char**) formalArgs->handles;
 
-#if FUTURE
-		if (formalArgs->used != actualArgs->used) {
-			ejsError(ep, "Bad number of args. Should be %d", formalArgs->used);
+		if (formalArgs->used > actualArgs->used) {
+			ejsError(ep, "Bad number of args. Should be %d", 
+					 formalArgs->used);
 			return -1;
 		}
-#endif
 
 		/*
 		 *	Create the arguments and callee variables

Modified: branches/SAMBA_4_0/source/lib/appweb/esp/esp.h
===================================================================
--- branches/SAMBA_4_0/source/lib/appweb/esp/esp.h	2005-07-20 05:13:01 UTC (rev 8630)
+++ branches/SAMBA_4_0/source/lib/appweb/esp/esp.h	2005-07-20 05:40:24 UTC (rev 8631)
@@ -103,7 +103,7 @@
 				int lifetime, const char *path, bool secure);
 	void	(*setHeader)(EspHandle handle, const char *value, bool allowMultiple);
 	void	(*setResponseCode)(EspHandle handle, int code);
-	int		(*writeBlock)(EspHandle handle, char *buf, int size);
+	int		(*writeBlock)(EspHandle handle, const char *buf, int size);
 	int		(*writeFmt)(EspHandle handle, char *fmt, ...);
 #if BLD_FEATURE_MULTITHREAD
 	void 	(*lock)(void *lockData);



More information about the samba-cvs mailing list