From: <cli...@li...> - 2005-03-22 04:13:07
|
Send clisp-cvs mailing list submissions to cli...@li... To subscribe or unsubscribe via the World Wide Web, visit https://lists.sourceforge.net/lists/listinfo/clisp-cvs or, via email, send a message with subject or body 'help' to cli...@li... You can reach the person managing the list at cli...@li... When replying, please edit your Subject line so it is more specific than "Re: Contents of clisp-cvs digest..." CLISP CVS commits for today Today's Topics: 1. clisp/modules/postgresql postgresql.lisp,1.12,1.13 (Sam Steingold) 2. clisp/src ChangeLog,1.4394,1.4395 (Sam Steingold) 3. clisp/src ChangeLog,1.4395,1.4396 (Sam Steingold) 4. clisp/modules/rawsock sock.lisp,1.12,1.13 preload.lisp,1.1,1.2 (Sam Steingold) 5. clisp/modules/rawsock rawsock.c,1.24,1.25 (Sam Steingold) 6. clisp/src ChangeLog,1.4396,1.4397 (Sam Steingold) 7. clisp/modules/wildcard wildcard.lisp,1.10,1.11 (Sam Steingold) 8. clisp/src ChangeLog,1.4397,1.4398 (Sam Steingold) 9. clisp/src spvw.d,1.355,1.356 ChangeLog,1.4398,1.4399 (Sam Steingold) 10. clisp/src TODO,1.79,1.80 (Sam Steingold) 11. clisp/modules/queens queens.c,1.2,1.3 callqueens.c,1.3,1.4 (Sam Steingold) 12. clisp/src ChangeLog,1.4399,1.4400 (Sam Steingold) --__--__-- Message: 1 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/modules/postgresql postgresql.lisp,1.12,1.13 Date: Mon, 21 Mar 2005 16:25:02 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/modules/postgresql In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8315/modules/postgresql Modified Files: postgresql.lisp Log Message: (PQinitSSL): commented out: not found in libpq 8.0 Index: postgresql.lisp =================================================================== RCS file: /cvsroot/clisp/clisp/modules/postgresql/postgresql.lisp,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- postgresql.lisp 16 Mar 2005 21:24:11 -0000 1.12 +++ postgresql.lisp 21 Mar 2005 16:24:59 -0000 1.13 @@ -204,8 +204,8 @@ ;; ifdef USE_SSL ;; (def-call-out PQgetssl (:arguments (conn PGconn)) (:return-type SSL)) (def-call-out PQgetssl (:arguments (conn PGconn)) (:return-type c-pointer)) -;; Tell libpq whether it needs to initialize OpenSSL -(def-call-out PQinitSSL (:return-type nil) (:arguments (do_init int))) +;; Tell libpq whether it needs to initialize OpenSSL (not in libpq 8.0) +;(def-call-out PQinitSSL (:return-type nil) (:arguments (do_init int))) (def-call-out PQsetErrorVerbosity (:return-type PGVerbosity) (:arguments (conn PGconn) (verbosity PGVerbosity))) --__--__-- Message: 2 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/src ChangeLog,1.4394,1.4395 Date: Mon, 21 Mar 2005 16:25:01 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8315/src Modified Files: ChangeLog Log Message: (PQinitSSL): commented out: not found in libpq 8.0 Index: ChangeLog =================================================================== RCS file: /cvsroot/clisp/clisp/src/ChangeLog,v retrieving revision 1.4394 retrieving revision 1.4395 diff -u -d -r1.4394 -r1.4395 --- ChangeLog 21 Mar 2005 15:01:00 -0000 1.4394 +++ ChangeLog 21 Mar 2005 16:24:30 -0000 1.4395 @@ -1,5 +1,10 @@ 2005-03-21 Sam Steingold <sd...@gn...> + * modules/postgresql/postgresql.lisp (PQinitSSL): + commented out: not found in libpq 8.0 + +2005-03-21 Sam Steingold <sd...@gn...> + * modules/pcre/configure.in: use AC_LIB_LINKFLAGS([pcre]) * modules/pcre/Makefile.in: use PCRECPPFLAGS instead of CPPFLAGS to pass the result of --with-pcre-prefix to CC --__--__-- Message: 3 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/src ChangeLog,1.4395,1.4396 Date: Mon, 21 Mar 2005 17:00:11 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24448/src Modified Files: ChangeLog Log Message: shadow LISTEN Index: ChangeLog =================================================================== RCS file: /cvsroot/clisp/clisp/src/ChangeLog,v retrieving revision 1.4395 retrieving revision 1.4396 diff -u -d -r1.4395 -r1.4396 --- ChangeLog 21 Mar 2005 16:24:30 -0000 1.4395 +++ ChangeLog 21 Mar 2005 17:00:02 -0000 1.4396 @@ -1,5 +1,11 @@ 2005-03-21 Sam Steingold <sd...@gn...> + * modules/rawsock/sock.lisp: shadow LISTEN + * modules/rawsock/preload.lisp: ditto + Reported by Yaroslav Kavenchuk <kav...@je...> + +2005-03-21 Sam Steingold <sd...@gn...> + * modules/postgresql/postgresql.lisp (PQinitSSL): commented out: not found in libpq 8.0 --__--__-- Message: 4 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/modules/rawsock sock.lisp,1.12,1.13 preload.lisp,1.1,1.2 Date: Mon, 21 Mar 2005 17:00:11 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/modules/rawsock In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24448/modules/rawsock Modified Files: sock.lisp preload.lisp Log Message: shadow LISTEN Index: sock.lisp =================================================================== RCS file: /cvsroot/clisp/clisp/modules/rawsock/sock.lisp,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- sock.lisp 25 Jan 2005 14:35:13 -0000 1.12 +++ sock.lisp 21 Mar 2005 17:00:09 -0000 1.13 @@ -7,6 +7,7 @@ (defpackage #:rawsock (:documentation "Raw Socket access") (:use #:lisp) + (:shadow #:listen) ; an ANSI CL symbol (:export #:buffer #:open-unix-socket #:open-unix-socket-stream #:accept #:bind #:connect #:getpeername #:getsockname Index: preload.lisp =================================================================== RCS file: /cvsroot/clisp/clisp/modules/rawsock/preload.lisp,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- preload.lisp 21 Apr 2004 21:24:12 -0000 1.1 +++ preload.lisp 21 Mar 2005 17:00:09 -0000 1.2 @@ -1 +1,2 @@ (make-package "RAWSOCK") +(shadow "LISTEN" "RAWSOCK") --__--__-- Message: 5 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/modules/rawsock rawsock.c,1.24,1.25 Date: Mon, 21 Mar 2005 17:12:21 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/modules/rawsock In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30270/modules/rawsock Modified Files: rawsock.c Log Message: (HTONL, NTOHL, HTONS, NTOHS): define even when the OS lacks the C functions; in that case, return the argument on the assumption that the host order is the same as the network order Index: rawsock.c =================================================================== RCS file: /cvsroot/clisp/clisp/modules/rawsock/rawsock.c,v retrieving revision 1.24 retrieving revision 1.25 diff -u -d -r1.24 -r1.25 --- rawsock.c 18 Feb 2005 18:42:29 -0000 1.24 +++ rawsock.c 21 Mar 2005 17:12:17 -0000 1.25 @@ -152,34 +152,37 @@ } while(0) /* ================== arpa/inet.h interface ================== */ -#if defined(HAVE_HTONL) +/* define even when the OS lacks the C functions; in that case, + return the argument on the assumption + that the host order is the same as the network order */ DEFUN(RAWSOCK:HTONL, num) { uint32 arg = I_to_uint32(check_uint32(popSTACK())); +#if defined(HAVE_HTONL) begin_system_call(); arg = htonl(arg); end_system_call(); +#endif VALUES1(uint32_to_I(arg)); } -#endif -#if defined(HAVE_NTOHL) DEFUN(RAWSOCK:NTOHL, num) { uint32 arg = I_to_uint32(check_uint32(popSTACK())); +#if defined(HAVE_NTOHL) begin_system_call(); arg = ntohl(arg); end_system_call(); +#endif VALUES1(uint32_to_I(arg)); } -#endif -#if defined(HAVE_HTONS) DEFUN(RAWSOCK:HTONS, num) { uint16 arg = I_to_uint16(check_uint16(popSTACK())); +#if defined(HAVE_HTONS) begin_system_call(); arg = htons(arg); end_system_call(); +#endif VALUES1(uint16_to_I(arg)); } -#endif -#if defined(HAVE_NTOHS) DEFUN(RAWSOCK:NTOHS, num) { uint16 arg = I_to_uint16(check_uint16(popSTACK())); +#if defined(HAVE_NTOHS) begin_system_call(); arg = ntohs(arg); end_system_call(); +#endif VALUES1(uint16_to_I(arg)); } -#endif DEFUN(RAWSOCK:CONVERT-ADDRESS, family address) { int family = check_socket_domain(STACK_1); if (stringp(STACK_0)) { --__--__-- Message: 6 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/src ChangeLog,1.4396,1.4397 Date: Mon, 21 Mar 2005 17:12:20 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30270/src Modified Files: ChangeLog Log Message: (HTONL, NTOHL, HTONS, NTOHS): define even when the OS lacks the C functions; in that case, return the argument on the assumption that the host order is the same as the network order Index: ChangeLog =================================================================== RCS file: /cvsroot/clisp/clisp/src/ChangeLog,v retrieving revision 1.4396 retrieving revision 1.4397 diff -u -d -r1.4396 -r1.4397 --- ChangeLog 21 Mar 2005 17:00:02 -0000 1.4396 +++ ChangeLog 21 Mar 2005 17:11:45 -0000 1.4397 @@ -1,5 +1,12 @@ 2005-03-21 Sam Steingold <sd...@gn...> + * modules/rawsock/rawsock.c (HTONL, NTOHL, HTONS, NTOHS): define + even when the OS lacks the C functions; in that case, return the + argument on the assumption that the host order is the same as the + network order + +2005-03-21 Sam Steingold <sd...@gn...> + * modules/rawsock/sock.lisp: shadow LISTEN * modules/rawsock/preload.lisp: ditto Reported by Yaroslav Kavenchuk <kav...@je...> --__--__-- Message: 7 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/modules/wildcard wildcard.lisp,1.10,1.11 Date: Mon, 21 Mar 2005 17:21:18 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/modules/wildcard In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2192/modules/wildcard Modified Files: wildcard.lisp Log Message: include <config.h> because it defines fnmatch as an alias to posix_fnmatch when the included fnmatch implementation is used Index: wildcard.lisp =================================================================== RCS file: /cvsroot/clisp/clisp/modules/wildcard/wildcard.lisp,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- wildcard.lisp 25 Jan 2005 14:35:12 -0000 1.10 +++ wildcard.lisp 21 Mar 2005 17:21:15 -0000 1.11 @@ -10,6 +10,7 @@ (default-foreign-language :stdc) +(c-lines "#include <config.h>~%") (c-lines "#include <fnmatch.h>~%") (def-call-out fnmatch --__--__-- Message: 8 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/src ChangeLog,1.4397,1.4398 Date: Mon, 21 Mar 2005 17:21:17 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2192/src Modified Files: ChangeLog Log Message: include <config.h> because it defines fnmatch as an alias to posix_fnmatch when the included fnmatch implementation is used Index: ChangeLog =================================================================== RCS file: /cvsroot/clisp/clisp/src/ChangeLog,v retrieving revision 1.4397 retrieving revision 1.4398 diff -u -d -r1.4397 -r1.4398 --- ChangeLog 21 Mar 2005 17:11:45 -0000 1.4397 +++ ChangeLog 21 Mar 2005 17:20:46 -0000 1.4398 @@ -1,5 +1,12 @@ 2005-03-21 Sam Steingold <sd...@gn...> + * modules/wildcard/wildcard.lisp: include <config.h> + because it defines fnmatch as an alias to posix_fnmatch + when the included fnmatch implementation is used + Reported by Yaroslav Kavenchuk <kav...@je...> + +2005-03-21 Sam Steingold <sd...@gn...> + * modules/rawsock/rawsock.c (HTONL, NTOHL, HTONS, NTOHS): define even when the OS lacks the C functions; in that case, return the argument on the assumption that the host order is the same as the --__--__-- Message: 9 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/src spvw.d,1.355,1.356 ChangeLog,1.4398,1.4399 Date: Mon, 21 Mar 2005 21:36:19 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25836/src Modified Files: spvw.d ChangeLog Log Message: (init_module_2): do not allow redefinition of symbols in locked packages Index: spvw.d =================================================================== RCS file: /cvsroot/clisp/clisp/src/spvw.d,v retrieving revision 1.355 retrieving revision 1.356 diff -u -d -r1.355 -r1.356 --- spvw.d 18 Mar 2005 19:32:40 -0000 1.355 +++ spvw.d 21 Mar 2005 21:36:01 -0000 1.356 @@ -1546,6 +1546,17 @@ intern(symname,false,pack,&symbol); } subr_ptr->name = symbol; # complete Subr + if (pack_locked_p(Symbol_package(symbol)) + && !nullp(Symbol_function(symbol))) { /* package lock error */ + fprintf(stderr,GETTEXTL("module '%s' redefines symbol "),module->name); + nobject_out(stderr,symbol); + fprintf(stderr,GETTEXTL(" in the locked package ")); + nobject_out(stderr,Symbol_package(symbol)); + fprintf(stderr,GETTEXTL("\nold definition: ")); + nobject_out(stderr,Symbol_function(symbol)); + fprintf(stderr,"\n"); + quit_sofort(1); + } Symbol_function(symbol) = subr_tab_ptr_as_object(subr_ptr); # define function init_ptr++; subr_ptr++; }); Index: ChangeLog =================================================================== RCS file: /cvsroot/clisp/clisp/src/ChangeLog,v retrieving revision 1.4398 retrieving revision 1.4399 diff -u -d -r1.4398 -r1.4399 --- ChangeLog 21 Mar 2005 17:20:46 -0000 1.4398 +++ ChangeLog 21 Mar 2005 21:36:05 -0000 1.4399 @@ -1,5 +1,11 @@ 2005-03-21 Sam Steingold <sd...@gn...> + * spvw.d (init_module_2): do not allow redefinition of symbols in + locked packages + this should prevent bugs like the LISTEN bug also fixed today + +2005-03-21 Sam Steingold <sd...@gn...> + * modules/wildcard/wildcard.lisp: include <config.h> because it defines fnmatch as an alias to posix_fnmatch when the included fnmatch implementation is used --__--__-- Message: 10 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/src TODO,1.79,1.80 Date: Mon, 21 Mar 2005 23:33:18 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18737/src Modified Files: TODO Log Message: --with-dynamic-modules should _NOT_ make BASE_MODULES dynamic Index: TODO =================================================================== RCS file: /cvsroot/clisp/clisp/src/TODO,v retrieving revision 1.79 retrieving revision 1.80 diff -u -d -r1.79 -r1.80 --- TODO 18 Mar 2005 12:37:29 -0000 1.79 +++ TODO 21 Mar 2005 23:33:15 -0000 1.80 @@ -134,7 +134,7 @@ gettext.o(.text+0x7f):i18n/gettext.c:2296: undefined reference to `_I_to_L' gettext.o(.text+0xcb):i18n/gettext.c:2301: undefined reference to `_STACK' gettext.o(.text+0xd2):i18n/gettext.c:2301: undefined reference to `_symbol_tab_data' - +Also, --with-dynamic-modules should _NOT_ make BASE_MODULES dynamic. CLISP_LANGUAGE=german LC_ALL=C clisp -q --__--__-- Message: 11 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/modules/queens queens.c,1.2,1.3 callqueens.c,1.3,1.4 Date: Tue, 22 Mar 2005 01:42:25 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/modules/queens In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31664/modules/queens Modified Files: queens.c callqueens.c Log Message: use "modern" tools and formatting Index: callqueens.c =================================================================== RCS file: /cvsroot/clisp/clisp/modules/queens/callqueens.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- callqueens.c 19 Apr 2004 01:52:07 -0000 1.3 +++ callqueens.c 22 Mar 2005 01:42:23 -0000 1.4 @@ -11,26 +11,19 @@ /* extern declaration */ extern unsigned int queens (unsigned int n); -/* (USER::QUEENS n) returns the number of solutions to the n-queens problem. +/* + * (USER::QUEENS n) returns the number of solutions to the n-queens problem. * n ought to be an integer > 0, <= nmax. Otherwise it returns NIL. */ DEFUN(USER::QUEENS, n) { /* - * No garbage collection is a problem. So we get the argument from the - * STACK immediately. - */ - var object arg = popSTACK(); /* clean up STACK at the same time */ - /* - * If arg is an integer > 0, <= 100, it must be a nonnegative fixnum. - * We do the argument check in two steps: 1. check whether arg is a - * nonnegative fixnum. 2. Extract its value. 3. Check its value. + * garbage collection is not a problem, + * so we get the argument from the STACK immediately, + * and clean up STACK at the same time */ - if (!posfixnump(arg)) goto bad_arg; - {var uintL n = posfixnum_to_L(arg); - if (!(n>0 && n<=nmax)) goto bad_arg; - - /* Arguments are checked. Do our job: */ - { var uint32 result; + uintL n = posfixnum_to_L(check_posfixnum(popSTACK())); + if (n>0 && n<=nmax) { /* the argument is good. Do our job: */ + uint32 result; begin_call(); result = queens(n); /* call external function */ end_call(); @@ -39,14 +32,8 @@ * of problem we have and the amount of time queens() may have run). * So an `uint32' is enough, and the following call is appropriate. */ - value1 = uint32_to_I(result); /* convert result to nonnegative integer */ - mv_count=1; /* no "multiple" values */ - } - return; - } - - bad_arg: - /* We could issue an error. We prefer to return NIL here. */ - value1 = NIL; mv_count=1; return; + VALUES1(uint32_to_I(result)); /* convert result to a nonnegative integer */ + } else /* We could issue an error. We prefer to return NIL here. */ + VALUES1(NIL); } Index: queens.c =================================================================== RCS file: /cvsroot/clisp/clisp/modules/queens/queens.c,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- queens.c 6 Dec 2004 12:20:07 -0000 1.2 +++ queens.c 22 Mar 2005 01:42:23 -0000 1.3 @@ -1,7 +1,7 @@ /* Compute the number of solutions to the n-queens problem on a nxn checkboard. */ -/* dynamic data structures not needed for such a simple problem */ +/* dynamic data structures are not needed for such a simple problem */ #define nmax 100 int queens (int n) /* function definition in ISO/ANSI C style */ @@ -23,22 +23,24 @@ int i = 0; /* recursion depth */ int* Dptr = &dtab[0]; /* points to next free D(i) */ entry: /* enter recursion */ - i++; - if (i > n) - { counter++; } - else - { int j; - for (j = 1; j <= n; j++) - { if (freetab1[j]==0 && freetab2[j+i]==0 && freetab3[j-i]==0) - { freetab1[j]=1; freetab2[j+i]=1; freetab3[j-i]=1; - *Dptr++ = j; - goto entry; - comeback: - j = *--Dptr; - freetab1[j]=0; freetab2[j+i]=0; freetab3[j-i]=0; - } } } - i--; - if (i>0) goto comeback; + i++; + if (i > n) { + counter++; + } else { + int j; + for (j = 1; j <= n; j++) { + if (freetab1[j]==0 && freetab2[j+i]==0 && freetab3[j-i]==0) { + freetab1[j]=1; freetab2[j+i]=1; freetab3[j-i]=1; + *Dptr++ = j; + goto entry; + comeback: + j = *--Dptr; + freetab1[j]=0; freetab2[j+i]=0; freetab3[j-i]=0; + } + } + } + i--; + if (i>0) goto comeback; return counter; }} --__--__-- Message: 12 From: Sam Steingold <sd...@us...> To: cli...@li... Subject: clisp/src ChangeLog,1.4399,1.4400 Date: Tue, 22 Mar 2005 01:42:24 +0000 Reply-To: cli...@li... Update of /cvsroot/clisp/clisp/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31664/src Modified Files: ChangeLog Log Message: use "modern" tools and formatting Index: ChangeLog =================================================================== RCS file: /cvsroot/clisp/clisp/src/ChangeLog,v retrieving revision 1.4399 retrieving revision 1.4400 diff -u -d -r1.4399 -r1.4400 --- ChangeLog 21 Mar 2005 21:36:05 -0000 1.4399 +++ ChangeLog 22 Mar 2005 01:42:17 -0000 1.4400 @@ -1,5 +1,10 @@ 2005-03-21 Sam Steingold <sd...@gn...> + * modules/queens/queens.c, modules/queens/callqueens.c: + use "modern" tools and formatting + +2005-03-21 Sam Steingold <sd...@gn...> + * spvw.d (init_module_2): do not allow redefinition of symbols in locked packages this should prevent bugs like the LISTEN bug also fixed today --__--__-- _______________________________________________ clisp-cvs mailing list cli...@li... https://lists.sourceforge.net/lists/listinfo/clisp-cvs End of clisp-cvs Digest |