On 10/23/07, Vasiljevic Zoran <[EMAIL PROTECTED]> wrote:
>
> On 23.10.2007, at 19:25, Stephen Deasey wrote:
>
> >
> > test cfg-4.1 {global type check bool} -body {
> >     ns_setconfig section cfg-4.1 true
> >     expr {[ns_getconfig -bool section cfg-4.1] ? 1 : 0}
> > } -result 1
>
> Try again...



$ make

gcc -g -Wall -Wno-implicit-int -fPIC  -pipe
-I/home/sd/local/ns-HEADg/include
-I"/home/sd/local/tcl8.4.15g/include"  -DHAVE_CONFIG_H   -c -o
configrw.o configrw.c

configrw.c:219: error: conflicting types for 'Cfg_GetBool'
nsconfigrw.h:58: error: previous declaration of 'Cfg_GetBool' was here
configrw.c:265: error: conflicting types for 'Cfg_GetInt'
nsconfigrw.h:61: error: previous declaration of 'Cfg_GetInt' was here
configrw.c: In function 'Cfg_GetInt':
configrw.c:266: warning: passing argument 3 of 'Cfg_GetRange' discards
qualifiers from pointer target type
configrw.c: At top level:
configrw.c:291: error: conflicting types for 'Cfg_GetRange'
nsconfigrw.h:65: error: previous declaration of 'Cfg_GetRange' was here
make: *** [configrw.o] Error 1



Also:


> static int
> GetBoolFromParam(Param *param, int *result)
> {
>     if (param->type != IntType) {
>         int bool;
>         if (   STREQ (param->value, "1"   )
>             || STRIEQ(param->value, "y"   )
>             || STRIEQ(param->value, "yes" )
>             || STRIEQ(param->value, "on"  )
>             || STRIEQ(param->value, "t"   )
>             || STRIEQ(param->value, "true")) {
>             param->intval = 1;


int Tcl_GetBoolean(Tcl_Interp *, CONST char *string, int *boolPtr)

  http://www.tcl.tk/man/tcl8.4/TclLib/GetInt.htm

(You can pass  it a NULL interp)

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
naviserver-devel mailing list
naviserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/naviserver-devel

Reply via email to