You can subscribe to this list here.
2005 |
Jan
|
Feb
(32) |
Mar
(56) |
Apr
(92) |
May
(39) |
Jun
(226) |
Jul
(98) |
Aug
(66) |
Sep
|
Oct
(153) |
Nov
(43) |
Dec
(42) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(97) |
Feb
(141) |
Mar
(147) |
Apr
(80) |
May
(51) |
Jun
(93) |
Jul
(88) |
Aug
(50) |
Sep
(179) |
Oct
(48) |
Nov
(82) |
Dec
(71) |
2007 |
Jan
(42) |
Feb
(46) |
Mar
(123) |
Apr
(21) |
May
(139) |
Jun
(59) |
Jul
(34) |
Aug
(57) |
Sep
(47) |
Oct
(137) |
Nov
(49) |
Dec
(12) |
2008 |
Jan
(10) |
Feb
(8) |
Mar
(63) |
Apr
(17) |
May
(34) |
Jun
(38) |
Jul
(16) |
Aug
(62) |
Sep
(9) |
Oct
(121) |
Nov
(38) |
Dec
(4) |
2009 |
Jan
|
Feb
(11) |
Mar
(9) |
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2010 |
Jan
|
Feb
|
Mar
(4) |
Apr
(10) |
May
(1) |
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2011 |
Jan
(1) |
Feb
(1) |
Mar
(3) |
Apr
(2) |
May
|
Jun
|
Jul
|
Aug
(3) |
Sep
(2) |
Oct
(1) |
Nov
|
Dec
(12) |
2012 |
Jan
(26) |
Feb
(1) |
Mar
(15) |
Apr
(1) |
May
(1) |
Jun
(7) |
Jul
(2) |
Aug
|
Sep
(1) |
Oct
(52) |
Nov
(8) |
Dec
(25) |
2013 |
Jan
(35) |
Feb
(14) |
Mar
(10) |
Apr
(10) |
May
(29) |
Jun
(16) |
Jul
(5) |
Aug
(8) |
Sep
(8) |
Oct
(6) |
Nov
(1) |
Dec
(3) |
2014 |
Jan
(16) |
Feb
(13) |
Mar
(5) |
Apr
(9) |
May
(21) |
Jun
(6) |
Jul
(5) |
Aug
(2) |
Sep
(59) |
Oct
(115) |
Nov
(122) |
Dec
(45) |
2015 |
Jan
(31) |
Feb
(32) |
Mar
(19) |
Apr
(25) |
May
(3) |
Jun
(4) |
Jul
(18) |
Aug
(3) |
Sep
(23) |
Oct
(11) |
Nov
(17) |
Dec
(12) |
2016 |
Jan
(20) |
Feb
(27) |
Mar
(20) |
Apr
(40) |
May
(35) |
Jun
(48) |
Jul
(44) |
Aug
(51) |
Sep
(18) |
Oct
(42) |
Nov
(39) |
Dec
(29) |
2017 |
Jan
(37) |
Feb
(34) |
Mar
(20) |
Apr
(37) |
May
(10) |
Jun
(2) |
Jul
(14) |
Aug
(15) |
Sep
(25) |
Oct
(29) |
Nov
(15) |
Dec
(29) |
2018 |
Jan
(5) |
Feb
(15) |
Mar
(6) |
Apr
(20) |
May
(39) |
Jun
(39) |
Jul
(17) |
Aug
(20) |
Sep
(10) |
Oct
(17) |
Nov
(20) |
Dec
(8) |
2019 |
Jan
(28) |
Feb
(21) |
Mar
(13) |
Apr
(44) |
May
(44) |
Jun
(28) |
Jul
(51) |
Aug
(30) |
Sep
(7) |
Oct
(20) |
Nov
(8) |
Dec
(21) |
2020 |
Jan
(27) |
Feb
(5) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Stephen D. <sd...@us...> - 2005-10-20 23:25:47
|
Update of /cvsroot/naviserver/naviserver/nsdbtest In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26491/nsdbtest Log Message: Directory /cvsroot/naviserver/naviserver/nsdbtest added to the repository |
From: Vlad S. <ser...@us...> - 2005-10-20 18:30:55
|
Update of /cvsroot/naviserver/naviserver/include In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14944/include Modified Files: ns.h Log Message: compilation C++ modules enabled Index: ns.h =================================================================== RCS file: /cvsroot/naviserver/naviserver/include/ns.h,v retrieving revision 1.53 retrieving revision 1.54 diff -C2 -d -r1.53 -r1.54 *** ns.h 9 Oct 2005 22:14:53 -0000 1.53 --- ns.h 20 Oct 2005 18:30:41 -0000 1.54 *************** *** 1202,1206 **** NS_EXTERN void Ns_RegisterRequest(CONST char *server, CONST char *method, CONST char *url, ! Ns_OpProc *proc, Ns_Callback *delete, void *arg, int flags) NS_GNUC_NONNULL(1) NS_GNUC_NONNULL(2) NS_GNUC_NONNULL(3) NS_GNUC_NONNULL(4); --- 1202,1206 ---- NS_EXTERN void Ns_RegisterRequest(CONST char *server, CONST char *method, CONST char *url, ! Ns_OpProc *proc, Ns_Callback *del, void *arg, int flags) NS_GNUC_NONNULL(1) NS_GNUC_NONNULL(2) NS_GNUC_NONNULL(3) NS_GNUC_NONNULL(4); |
From: Vlad S. <ser...@us...> - 2005-10-20 18:30:55
|
Update of /cvsroot/naviserver/naviserver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14944 Modified Files: ChangeLog Log Message: compilation C++ modules enabled Index: ChangeLog =================================================================== RCS file: /cvsroot/naviserver/naviserver/ChangeLog,v retrieving revision 1.223 retrieving revision 1.224 diff -C2 -d -r1.223 -r1.224 *** ChangeLog 20 Oct 2005 17:56:17 -0000 1.223 --- ChangeLog 20 Oct 2005 18:30:41 -0000 1.224 *************** *** 2,5 **** --- 2,7 ---- * nsd/init.tcl: fixed to be able to load Tcl modules + * include/ns.h: changed reserved keyword delete so C++ + module scan be compiled 2005-10-20 Bernd Eidenschink <ei...@us...> |
From: Vlad S. <ser...@us...> - 2005-10-20 17:56:31
|
Update of /cvsroot/naviserver/naviserver/nsd In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5297/nsd Modified Files: init.tcl Log Message: loading Tcl modules enabled again Index: init.tcl =================================================================== RCS file: /cvsroot/naviserver/naviserver/nsd/init.tcl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** init.tcl 9 Oct 2005 22:27:24 -0000 1.4 --- init.tcl 20 Oct 2005 17:56:17 -0000 1.5 *************** *** 634,638 **** if {![string equal $modules ""]} { foreach {module file} [ns_set array $modules] { ! if {![string equal [string tolower $module] tcl]} { ns_moduleload $module $file } --- 634,638 ---- if {![string equal $modules ""]} { foreach {module file} [ns_set array $modules] { ! if {![string equal [string tolower $file] tcl]} { ns_moduleload $module $file } |
From: Vlad S. <ser...@us...> - 2005-10-20 17:56:31
|
Update of /cvsroot/naviserver/naviserver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5297 Modified Files: ChangeLog Log Message: loading Tcl modules enabled again Index: ChangeLog =================================================================== RCS file: /cvsroot/naviserver/naviserver/ChangeLog,v retrieving revision 1.222 retrieving revision 1.223 diff -C2 -d -r1.222 -r1.223 *** ChangeLog 20 Oct 2005 17:02:45 -0000 1.222 --- ChangeLog 20 Oct 2005 17:56:17 -0000 1.223 *************** *** 1,2 **** --- 1,6 ---- + 2005-10-20 Vlad Seryakov <ser...@us...> + + * nsd/init.tcl: fixed to be able to load Tcl modules + 2005-10-20 Bernd Eidenschink <ei...@us...> |
Update of /cvsroot/naviserver/naviserver/tests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25378/tests Added Files: ns_conn.test ns_crypt.test ns_env.test ns_gifsize.test ns_info.test ns_httptime.test ns_jpegsize.test ns_mime.test ns_sha1.test Log Message: see ChangeLog --- NEW FILE: ns_info.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_info.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # package require tcltest 2.2 namespace import -force ::tcltest::* eval ::tcltest::configure $argv test ns_info-1.1 {basic syntax: plain call} -body { ns_info } -returnCodes error -result {wrong # args: should be "ns_info option"} test ns_info-1.2 {basic syntax: wrong argument} -body { ns_info 123 } -returnCodes error -result {bad option "123": must be address, argv0, boottime, builddate, callbacks, config, home, hostname, locks, log, major, minor, name, nsd, pageroot, patchlevel, pid, platform, pools, scheduled, server, servers, sockcallbacks, tag, tcllib, threads, uptime, version, winnt, filters, traces, or requestprocs} test ns_info-2.1.1 {basic operation} -body { ns_info address } -match "glob" -result "*.*.*.*" test ns_info-2.2.1 {basic operation} -body { ns_info argv0 } -result "./nsd/nsd" test ns_info-2.3.1 {basic operation} -body { string is int -strict [ns_info boottime] } -result 1 test ns_info-2.4.1 {basic operation builddate: positive if builddate = day of test} -body { foreach {month day year blub time} [split [ns_info builddate]] {break} set _todaybuilt [clock format [clock scan "$month $day $year"] -format "%d"] set _todaydate [clock format [clock scan "today"] -format "%d"] expr {$_todaybuilt == $_todaydate} } -result 1 test ns_info-2.5.1 {basic operation} -body { string is int -strict [llength [ns_info callbacks]] } -result 1 test ns_info-2.6.1 {basic operation} -body { ns_info config } -match "glob" -result "*.nscfg" test ns_info-2.7.1 {basic operation} -body { expr {[string length [ns_info home]]>1} } -result 1 test ns_info-2.8.1 {basic operation} -setup { set hostname_by_exec [exec hostname] } -body { string match [ns_info hostname] $hostname_by_exec } -result 1 test ns_info-2.9.1 {basic operation} -body { expr {[llength [ns_info locks]]>0} } -result 1 test ns_info-2.10.1 {basic operation} -body { expr {[file tail [ns_info log]] ne ""} } -result 1 test ns_info-2.11.1 {basic operation} -body { ns_info major } -result 4 test ns_info-2.12.1 {basic operation} -body { ns_info minor } -result 99 test ns_info-2.13.1 {basic operation} -body { ns_info name } -result "NaviServer" test ns_info-2.14.1 {basic operation} -body { file tail [ns_info nsd] } -result "nsd" test ns_info-2.15.1 {basic operation} -body { expr {[llength [split [ns_info pageroot] "/"]]>1} } -result 1 test ns_info-2.16.1 {basic operation} -body { ns_info patchlevel } -match "glob" -result "4.99.*" test ns_info-2.17.1 {basic operation} -body { expr {[ns_info pid] == [pid]} } -result 1 test ns_info-2.18.1 {basic operation} -body { expr {[ns_info platform] ne ""} } -result 1 test ns_info-2.19.1 {basic operation} -body { expr {[llength [ns_info pools]]>0} } -result 1 test ns_info-2.20.1 {basic operation} -body { string is int -strict [llength [ns_info scheduled]] } -result 1 test ns_info-2.21.1 {basic operation} -body { ns_info server } -result "test" test ns_info-2.22.1 {basic operation} -body { ns_info servers } -match "regexp" -result "testvhost|testvhost2|test" test ns_info-2.23.1 {basic operation} -body { ns_info sockcallbacks } -result "" test ns_info-2.24.1 {basic operation} -body { ns_info tag } -match "glob" -result "*Name*" test ns_info-2.25.1 {basic operation} -body { ns_info tcllib } -match "glob" -result "*modules*" test ns_info-2.26.1 {basic operation} -body { expr {[llength [ns_info threads]]>2} } -result 1 test ns_info-2.27.1 {basic operation} -body { set expected_threads 0 foreach _thread [ns_info threads] { switch -- [lindex $_thread 0] { "-driver-" - "-sched-" - "-main-" {} "default" { set expected_threads 1 } } } set expected_threads } -result 1 test ns_info-2.28.1 {basic operation} -body { expr {[ns_info uptime]>1} } -result 1 test ns_info-2.29.1 {basic operation} -body { ns_info version } -result "4.99" test ns_info-2.30.1 {basic operation} -body { string is int -strict [ns_info winnt] } -result 1 test ns_info-2.31.1 {basic operation} -body { ns_info filters } -result "" test ns_info-2.31.2 {basic operation} -setup { proc _filter_do_nothing {args} { return "" } ns_register_filter preauth GET / _filter_do_nothing } -body { ns_info filters } -result {{GET / preauth ns:tclfilter _filter_do_nothing {}}} test ns_info-2.32.1 {basic operation} -body { expr {[llength [ns_info traces]]>-1} } -result 1 test ns_info-2.33.1 {basic operation} -body { expr {[llength [ns_info requestprocs]]>0} } -result 1 cleanupTests --- NEW FILE: ns_sha1.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_sha1.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # package require tcltest 2.2 namespace import -force ::tcltest::* eval ::tcltest::configure $argv test ns_sha1-1.1 {basic syntax: plain call} -body { ns_sha1 } -returnCodes error -result {wrong # args: should be "ns_sha1 string"} test ns_sha1-1.2 {basic syntax: plain call} -body { ns_sha1 } -returnCodes error -result {wrong # args: should be "ns_sha1 string"} test ns_sha1-2.1 {basic operation} -body { ns_sha1 foo } -result "0BEEC7B5EA3F0FDBC95D0DD47F3C5BC275DA8A33" test ns_sha1-2.2 {basic operation} -body { for {set i 0} {$i < 999} {incr i +1} { set nssha1([ns_sha1 foo]) . } llength [array names nssha1] } -cleanup { array unset nssha1 } -result 1 test ns_sha1-2.3 {basic operation} -body { for {set i 0} {$i < 999} {incr i +1} { set nssha1([ns_sha1 $i]) . } llength [array names nssha1] } -cleanup { array unset nssha1 } -result 999 test ns_sha1-2.4 {basic operation} -body { set hash1 [ns_sha1 ""] set hash2 [ns_sha1 {}] set hash3 [ns_sha1 [array names fjfjfjfjfj]] expr {($hash1 eq $hash2) == ($hash2 eq $hash3)} } -result 1 cleanupTests --- NEW FILE: ns_conn.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_conn.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # package require tcltest 2.2 namespace import -force ::tcltest::* eval ::tcltest::configure $argv test ns_conn-1.1 {basic syntax: plain call} -body { ns_conn } -returnCodes error -result {wrong # args: should be "ns_conn option"} test ns_conn-1.2 {basic syntax: wrong argument} -body { ns_conn 123 } -returnCodes error -result {bad option "123": must be authpassword, authuser, close, content, contentlength, copy, channel, driver, encoding, files, fileoffset, filelength, fileheaders, flags, form, headers, host, id, isconnected, location, method, outputheaders, peeraddr, peerport, port, protocol, query, request, server, sock, start, status, url, urlc, urlencoding, urlv, version, write_encoded, chunked, or responseversion} test ns_conn-2.1 {basic operation} -body { ns_conn close } -returnCodes error -result {no current connection} cleanupTests --- NEW FILE: ns_jpegsize.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_jpegsize.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # # Thanks to Michael P. Lex (Kinetiqa) # package require tcltest 2.2 namespace import -force ::tcltest::* set home [ns_config test home] if {[file exists "${home}/images/empty.jpg"] && [file readable "${home}/images/empty.jpg"]} { testConstraint fileExistsEmpty true } if {[file exists "${home}/images/broken.jpg"] && [file readable "${home}/images/broken.jpg"]} { testConstraint fileExistsBroken true } if {[file exists "${home}/images/color5x200.jpg"] && [file readable "${home}/images/color5x200.jpg"]} { testConstraint fileExistsColor true } if {[file exists "${home}/images/color5x200_progressive.jpg"] && [file readable "${home}/images/color5x200_progressive.jpg"]} { testConstraint fileExistsProgressive true } test ns_jpegsize-1.1 {syntax} -body { ns_jpegsize } -returnCodes error -result {wrong # args: should be "ns_jpegsize jpeg_file"} test ns_jpegsize-2.1 {file does not exist} -body { ns_jpegsize "${home}/images/noexist.jpg" } -returnCodes error -match "glob" -result {couldn't open "*": no such file or directory} test ns_jpegsize-2.2 {file is empty} -constraints fileExistsEmpty -body { ns_jpegsize "${home}/images/empty.jpg" } -returnCodes error -match "glob" -result {invalid jpeg file*} test ns_jpegsize-2.3 {file is broken} -constraints fileExistsBroken -body { ns_jpegsize "${home}/images/broken.jpg" } -returnCodes error -match "glob" -result {invalid jpeg file*} test ns_jpegsize-2.4 {normal jpeg} -constraints fileExistsColor -body { ns_jpegsize "${home}/images/color5x200.jpg" } -result [list 5 200] test ns_jpegsize-2.5 {normal progressive jpeg} -constraints fileExistsProgressive -body { ns_jpegsize "${home}/images/color5x200_progressive.jpg" } -result [list 5 200] cleanupTests --- NEW FILE: ns_env.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_env.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # package require tcltest 2.2 namespace import -force ::tcltest::* eval ::tcltest::configure $argv test ns_env-1.1 {basic syntax} -body { ns_env } -returnCodes error -result {wrong # args: should be "ns_env command ?args ...?"} test ns_env-1.2 {basic syntax} -body { ns_env 123 } -returnCodes error -result {unknown command "123": should be exists, names, get, set, or unset} test ns_env-1.3 {basic syntax} -body { ns_env get } -returnCodes error -result {wrong # args: should be "ns_env get ?-nocomplain? name"} test ns_env-2.1 {basic operation: set, exists} -setup { ns_env set foo bar } -body { ns_env exists foo } -cleanup { ns_env unset foo } -result 1 test ns_env-2.2 {basic operation: set, get} -setup { ns_env set foo bar } -body { ns_env get foo } -cleanup { ns_env unset foo } -result "bar" test ns_env-2.3 {basic operation: unset} -setup { ns_env set foo bar } -body { ns_env unset foo ns_env exists foo } -result 0 test ns_env-2.4 {basic operation: names} -setup { ns_env set zhzhzhzh bar } -body { expr {[lsearch -exact [ns_env names] "zhzhzhzh"]>-1} } -result 1 test ns_env-2.5 {basic operation: get -nocomplain} -body { # note that this throws an error but the test case # tests the implied behaviour ns_env get -nocomplain NXNXNXNX } -result "" test ns_env-2.6 {basic operation: get} -body { # note that the test case expects the implied behaviour ns_env get NXNXNXNX } -returnCodes error -result {no such environment variable: NXNXNXNX} cleanupTests --- NEW FILE: ns_crypt.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_crypt.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # package require tcltest 2.2 namespace import -force ::tcltest::* eval ::tcltest::configure $argv test ns_crypt-1.1 {basic syntax: plain call} -body { ns_crypt } -returnCodes error -result {wrong # args: should be "ns_crypt key salt"} test ns_crypt-1.2 {basic syntax: only key} -body { ns_crypt 123 } -returnCodes error -result {wrong # args: should be "ns_crypt key salt"} test ns_crypt-1.3 {basic syntax: key but empty salt argument} -body { ns_crypt 123 "" } -result "" test ns_crypt-1.4 {basic syntax: empty key but salt argument} -body { ns_crypt "" 12 } -result "12UFlHxel6uMM" test ns_crypt-1.5 {basic syntax: empty args} -body { ns_crypt "" "" } -result "" test ns_crypt-2.1 {basic operation} -body { ns_crypt foo ba } -result "ba4TuD1iozTxw" test ns_crypt-2.2 {basic operation} -body { for {set i 0} {$i < 999} {incr i +1} { set nscrypt([ns_crypt foo ba]) . } llength [array names nscrypt] } -cleanup { array unset nscrypt } -result 1 test ns_crypt-2.3 {basic operation} -body { for {set i 0} {$i < 99} {incr i +1} { set nscrypt([ns_crypt "foo" $i]) . } llength [array names nscrypt] } -cleanup { array unset nscrypt } -result 99 test ns_crypt-3.1 {usability for *nix like passwords: basic} -body { ns_crypt mypassword XL } -result "XL/CpuZPF/frI" test ns_crypt-3.1 {usability for *nix like passwords: length} -body { string length [ns_crypt mypassword XL] } -result 13 test ns_crypt-3.1 {usability for *nix like passwords: salt} -body { string range [ns_crypt mypassword XL] 0 1 } -result "XL" cleanupTests --- NEW FILE: ns_mime.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_mime.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # package require tcltest 2.2 namespace import -force ::tcltest::* eval ::tcltest::configure $argv test ns_uuencode-1.1 {basic syntax: plain call} -body { ns_uuencode } -returnCodes error -result {wrong # args: should be "ns_uuencode string"} test ns_uudecode-1.2 {basic syntax: plain call} -body { ns_uudecode } -returnCodes error -result {wrong # args: should be "ns_uudecode string"} test ns_base64encode-1.3 {basic syntax: plain call} -body { ns_base64encode } -returnCodes error -result {wrong # args: should be "ns_base64encode string"} test ns_base64decode-1.4 {basic syntax: plain call} -body { ns_base64decode } -returnCodes error -result {wrong # args: should be "ns_base64decode string"} test ns_uuencode-2.1 {basic operation ns_uuencode} -body { ns_uuencode "true friends stab you in the front" } -result "dHJ1ZSBmcmllbmRzIHN0YWIgeW91IGluIHRoZSBmcm9udA==" test ns_uudecode-2.2 {basic operation ns_uudecode} -body { ns_uudecode "dHJ1ZSBmcmllbmRzIHN0YWIgeW91IGluIHRoZSBmcm9udA==" } -result "true friends stab you in the front" test ns_base64encode-3.1 {basic operation ns_base64encode} -body { ns_base64encode "true friends stab you in the front" } -result "dHJ1ZSBmcmllbmRzIHN0YWIgeW91IGluIHRoZSBmcm9udA==" test ns_base64decode-3.2 {basic operation ns_base64decode} -body { ns_base64decode "dHJ1ZSBmcmllbmRzIHN0YWIgeW91IGluIHRoZSBmcm9udA==" } -result "true friends stab you in the front" #test ns_uuencode-4.1 {basic operation: caused server abort} -body { # ns_uuencode @ #} -match "glob" -result "*" test ns_guesstype-5.1 {basic syntax: ns_guesstype} -body { ns_guesstype } -returnCodes error -result {wrong # args: should be "ns_guesstype filename"} test ns_guesstype-5.2 {basic syntax: ns_guesstype} -body { ns_guesstype x } -result "*/*" test ns_guesstype-6.1 {basic operation: ns_guesstype} -body { ns_guesstype "filename.adp" } -match "glob" -result "text/html;*" test ns_guesstype-6.2 {basic operation: ns_guesstype} -body { ns_guesstype "filename.dci" } -match "glob" -result "text/html;*" test ns_guesstype-6.3 {basic operation: ns_guesstype} -body { ns_guesstype "filename.htm" } -match "glob" -result "text/html;*" test ns_guesstype-6.4 {basic operation: ns_guesstype} -body { ns_guesstype "filename.html" } -match "glob" -result "text/html;*" test ns_guesstype-6.5 {basic operation: ns_guesstype} -body { ns_guesstype "filename.sht" } -match "glob" -result "text/html;*" test ns_guesstype-6.6 {basic operation: ns_guesstype} -body { ns_guesstype "filename.shtml" } -match "glob" -result "text/html;*" test ns_guesstype-6.7 {basic operation: ns_guesstype with extension .323} -body { ns_guesstype "filename.323" } -match "glob" -result "text/h323*" test ns_guesstype-6.8 {basic operation: ns_guesstype with extension .ai} -body { ns_guesstype "filename.ai" } -match "glob" -result "application/postscript*" test ns_guesstype-6.9 {basic operation: ns_guesstype with extension .aif} -body { ns_guesstype "filename.aif" } -match "glob" -result "audio/aiff*" test ns_guesstype-6.10 {basic operation: ns_guesstype with extension .aifc} -body { ns_guesstype "filename.aifc" } -match "glob" -result "audio/aiff*" test ns_guesstype-6.11 {basic operation: ns_guesstype with extension .aiff} -body { ns_guesstype "filename.aiff" } -match "glob" -result "audio/aiff*" test ns_guesstype-6.12 {basic operation: ns_guesstype with extension .ani} -body { ns_guesstype "filename.ani" } -match "glob" -result "application/x-navi-animation*" test ns_guesstype-6.13 {basic operation: ns_guesstype with extension .art} -body { ns_guesstype "filename.art" } -match "glob" -result "image/x-art*" test ns_guesstype-6.14 {basic operation: ns_guesstype with extension .asf} -body { ns_guesstype "filename.asf" } -match "glob" -result "video/x-ms-asf*" test ns_guesstype-6.15 {basic operation: ns_guesstype with extension .asr} -body { ns_guesstype "filename.asr" } -match "glob" -result "video/x-ms-asf*" test ns_guesstype-6.16 {basic operation: ns_guesstype with extension .asx} -body { ns_guesstype "filename.asx" } -match "glob" -result "video/x-ms-asf*" test ns_guesstype-6.17 {basic operation: ns_guesstype with extension .atom} -body { ns_guesstype "filename.atom" } -match "glob" -result "application/atom+xml*" test ns_guesstype-6.18 {basic operation: ns_guesstype with extension .au} -body { ns_guesstype "filename.au" } -match "glob" -result "audio/basic*" test ns_guesstype-6.19 {basic operation: ns_guesstype with extension .avi} -body { ns_guesstype "filename.avi" } -match "glob" -result "video/x-msvideo*" test ns_guesstype-6.20 {basic operation: ns_guesstype with extension .bin} -body { ns_guesstype "filename.bin" } -match "glob" -result "application/x-macbinary*" test ns_guesstype-6.21 {basic operation: ns_guesstype with extension .bmp} -body { ns_guesstype "filename.bmp" } -match "glob" -result "image/bmp*" test ns_guesstype-6.22 {basic operation: ns_guesstype with extension .cer} -body { ns_guesstype "filename.cer" } -match "glob" -result "application/x-x509-ca-cert*" test ns_guesstype-6.23 {basic operation: ns_guesstype with extension .class} -body { ns_guesstype "filename.class" } -match "glob" -result "application/octet-stream*" test ns_guesstype-6.24 {basic operation: ns_guesstype with extension .cpio} -body { ns_guesstype "filename.cpio" } -match "glob" -result "application/x-cpio*" test ns_guesstype-6.25 {basic operation: ns_guesstype with extension .css} -body { ns_guesstype "filename.css" } -match "glob" -result "text/css*" test ns_guesstype-6.26 {basic operation: ns_guesstype with extension .csv} -body { ns_guesstype "filename.csv" } -match "glob" -result "text/csv*" test ns_guesstype-6.27 {basic operation: ns_guesstype with extension .dcr} -body { ns_guesstype "filename.dcr" } -match "glob" -result "application/x-director*" test ns_guesstype-6.28 {basic operation: ns_guesstype with extension .der} -body { ns_guesstype "filename.der" } -match "glob" -result "application/x-x509-ca-cert*" test ns_guesstype-6.29 {basic operation: ns_guesstype with extension .dia} -body { ns_guesstype "filename.dia" } -match "glob" -result "application/x-dia*" test ns_guesstype-6.30 {basic operation: ns_guesstype with extension .dir} -body { ns_guesstype "filename.dir" } -match "glob" -result "application/x-director*" test ns_guesstype-6.31 {basic operation: ns_guesstype with extension .doc} -body { ns_guesstype "filename.doc" } -match "glob" -result "application/msword*" test ns_guesstype-6.32 {basic operation: ns_guesstype with extension .dot} -body { ns_guesstype "filename.dot" } -match "glob" -result "application/msword*" test ns_guesstype-6.33 {basic operation: ns_guesstype with extension .dp} -body { ns_guesstype "filename.dp" } -match "glob" -result "application/commonground*" test ns_guesstype-6.34 {basic operation: ns_guesstype with extension .dtd} -body { ns_guesstype "filename.dtd" } -match "glob" -result "application/xml-dtd*" test ns_guesstype-6.35 {basic operation: ns_guesstype with extension .dxr} -body { ns_guesstype "filename.dxr" } -match "glob" -result "application/x-director*" test ns_guesstype-6.36 {basic operation: ns_guesstype with extension .elm} -body { ns_guesstype "filename.elm" } -match "glob" -result "text/plain*" test ns_guesstype-6.37 {basic operation: ns_guesstype with extension .eml} -body { ns_guesstype "filename.eml" } -match "glob" -result "text/plain*" test ns_guesstype-6.38 {basic operation: ns_guesstype with extension .eps} -body { ns_guesstype "filename.eps" } -match "glob" -result "application/postscript*" test ns_guesstype-6.39 {basic operation: ns_guesstype with extension .exe} -body { ns_guesstype "filename.exe" } -match "glob" -result "application/octet-stream*" test ns_guesstype-6.40 {basic operation: ns_guesstype with extension .gbt} -body { ns_guesstype "filename.gbt" } -match "glob" -result "text/plain*" test ns_guesstype-6.41 {basic operation: ns_guesstype with extension .gif} -body { ns_guesstype "filename.gif" } -match "glob" -result "image/gif*" test ns_guesstype-6.42 {basic operation: ns_guesstype with extension .gz} -body { ns_guesstype "filename.gz" } -match "glob" -result "application/x-compressed*" test ns_guesstype-6.43 {basic operation: ns_guesstype with extension .h} -body { ns_guesstype "filename.h" } -match "glob" -result "text/plain*" test ns_guesstype-6.44 {basic operation: ns_guesstype with extension .hqx} -body { ns_guesstype "filename.hqx" } -match "glob" -result "application/mac-binhex40*" test ns_guesstype-6.45 {basic operation: ns_guesstype with extension .ico} -body { ns_guesstype "filename.ico" } -match "glob" -result "image/x-icon*" test ns_guesstype-6.46 {basic operation: ns_guesstype with extension .ica} -body { ns_guesstype "filename.ica" } -match "glob" -result "application/x-ica*" test ns_guesstype-6.47 {basic operation: ns_guesstype with extension .ics} -body { ns_guesstype "filename.ics" } -match "glob" -result "text/calendar*" test ns_guesstype-6.48 {basic operation: ns_guesstype with extension .ifb} -body { ns_guesstype "filename.ifb" } -match "glob" -result "text/calendar*" test ns_guesstype-6.49 {basic operation: ns_guesstype with extension .jar} -body { ns_guesstype "filename.jar" } -match "glob" -result "application/x-java-archive*" test ns_guesstype-6.50 {basic operation: ns_guesstype with extension .jfif} -body { ns_guesstype "filename.jfif" } -match "glob" -result "image/jpeg*" test ns_guesstype-6.51 {basic operation: ns_guesstype with extension .jng} -body { ns_guesstype "filename.jng" } -match "glob" -result "image/x-jng*" test ns_guesstype-6.52 {basic operation: ns_guesstype with extension .jpe} -body { ns_guesstype "filename.jpe" } -match "glob" -result "image/jpeg*" test ns_guesstype-6.53 {basic operation: ns_guesstype with extension .jpg} -body { ns_guesstype "filename.jpg" } -match "glob" -result "image/jpeg*" test ns_guesstype-6.54 {basic operation: ns_guesstype with extension .jpeg} -body { ns_guesstype "filename.jpeg" } -match "glob" -result "image/jpeg*" test ns_guesstype-6.55 {basic operation: ns_guesstype with extension .js} -body { ns_guesstype "filename.js" } -match "glob" -result "application/x-javascript*" test ns_guesstype-6.56 {basic operation: ns_guesstype with extension .ls} -body { ns_guesstype "filename.ls" } -match "glob" -result "application/x-javascript*" test ns_guesstype-6.57 {basic operation: ns_guesstype with extension .m3u} -body { ns_guesstype "filename.m3u" } -match "glob" -result "audio/x-mpegurl*" test ns_guesstype-6.58 {basic operation: ns_guesstype with extension .m4a} -body { ns_guesstype "filename.m4a" } -match "glob" -result "audio/mp4*" test ns_guesstype-6.59 {basic operation: ns_guesstype with extension .m4p} -body { ns_guesstype "filename.m4p" } -match "glob" -result "audio/mp4*" test ns_guesstype-6.60 {basic operation: ns_guesstype with extension .man} -body { ns_guesstype "filename.man" } -match "glob" -result "application/x-troff-man*" test ns_guesstype-6.61 {basic operation: ns_guesstype with extension .map} -body { ns_guesstype "filename.map" } -match "glob" -result "application/x-navimap*" test ns_guesstype-6.62 {basic operation: ns_guesstype with extension .mdb} -body { ns_guesstype "filename.mdb" } -match "glob" -result "application/x-msaccess*" test ns_guesstype-6.63 {basic operation: ns_guesstype with extension .mid} -body { ns_guesstype "filename.mid" } -match "glob" -result "audio/x-midi*" test ns_guesstype-6.64 {basic operation: ns_guesstype with extension .midi} -body { ns_guesstype "filename.midi" } -match "glob" -result "audio/x-midi*" test ns_guesstype-6.65 {basic operation: ns_guesstype with extension .mng} -body { ns_guesstype "filename.mng" } -match "glob" -result "image/x-mng*" test ns_guesstype-6.66 {basic operation: ns_guesstype with extension .mocha} -body { ns_guesstype "filename.mocha" } -match "glob" -result "application/x-javascript*" test ns_guesstype-6.67 {basic operation: ns_guesstype with extension .mov} -body { ns_guesstype "filename.mov" } -match "glob" -result "video/quicktime*" test ns_guesstype-6.68 {basic operation: ns_guesstype with extension .mp2} -body { ns_guesstype "filename.mp2" } -match "glob" -result "audio/mpeg*" test ns_guesstype-6.69 {basic operation: ns_guesstype with extension .mp3} -body { ns_guesstype "filename.mp3" } -match "glob" -result "audio/mpeg*" test ns_guesstype-6.70 {basic operation: ns_guesstype with extension .mp4} -body { ns_guesstype "filename.mp4" } -match "glob" -result "audio/mp4*" test ns_guesstype-6.71 {basic operation: ns_guesstype with extension .mpe} -body { ns_guesstype "filename.mpe" } -match "glob" -result "video/mpeg*" test ns_guesstype-6.72 {basic operation: ns_guesstype with extension .mpeg} -body { ns_guesstype "filename.mpeg" } -match "glob" -result "video/mpeg*" test ns_guesstype-6.73 {basic operation: ns_guesstype with extension .mpg} -body { ns_guesstype "filename.mpg" } -match "glob" -result "video/mpeg*" test ns_guesstype-6.74 {basic operation: ns_guesstype with extension .mpga} -body { ns_guesstype "filename.mpga" } -match "glob" -result "video/mpeg*" test ns_guesstype-6.75 {basic operation: ns_guesstype with extension .mpv2} -body { ns_guesstype "filename.mpv2" } -match "glob" -result "video/mpeg*" test ns_guesstype-6.76 {basic operation: ns_guesstype with extension .mxu} -body { ns_guesstype "filename.mxu" } -match "glob" -result "video/vnd.mpegurl*" test ns_guesstype-6.77 {basic operation: ns_guesstype with extension .nvd} -body { ns_guesstype "filename.nvd" } -match "glob" -result "application/x-navidoc*" test ns_guesstype-6.78 {basic operation: ns_guesstype with extension .nvm} -body { ns_guesstype "filename.nvm" } -match "glob" -result "application/x-navimap*" test ns_guesstype-6.79 {basic operation: ns_guesstype with extension .ogg} -body { ns_guesstype "filename.ogg" } -match "glob" -result "application/ogg*" test ns_guesstype-6.80 {basic operation: ns_guesstype with extension .pbm} -body { ns_guesstype "filename.pbm" } -match "glob" -result "image/x-portable-bitmap*" test ns_guesstype-6.81 {basic operation: ns_guesstype with extension .pdf} -body { ns_guesstype "filename.pdf" } -match "glob" -result "application/pdf*" test ns_guesstype-6.82 {basic operation: ns_guesstype with extension .pgm} -body { ns_guesstype "filename.pgm" } -match "glob" -result "image/x-portable-graymap*" test ns_guesstype-6.83 {basic operation: ns_guesstype with extension .pic} -body { ns_guesstype "filename.pic" } -match "glob" -result "image/pict*" test ns_guesstype-6.84 {basic operation: ns_guesstype with extension .pict} -body { ns_guesstype "filename.pict" } -match "glob" -result "image/pict*" test ns_guesstype-6.85 {basic operation: ns_guesstype with extension .pnm} -body { ns_guesstype "filename.pnm" } -match "glob" -result "image/x-portable-anymap*" test ns_guesstype-6.86 {basic operation: ns_guesstype with extension .png} -body { ns_guesstype "filename.png" } -match "glob" -result "image/png*" test ns_guesstype-6.87 {basic operation: ns_guesstype with extension .pot} -body { ns_guesstype "filename.pot" } -match "glob" -result "application/vnd.ms-powerpoint*" test ns_guesstype-6.88 {basic operation: ns_guesstype with extension .pps} -body { ns_guesstype "filename.pps" } -match "glob" -result "application/vnd.ms-powerpoint*" test ns_guesstype-6.89 {basic operation: ns_guesstype with extension .ppt} -body { ns_guesstype "filename.ppt" } -match "glob" -result "application/vnd.ms-powerpoint*" test ns_guesstype-6.90 {basic operation: ns_guesstype with extension .ps} -body { ns_guesstype "filename.ps" } -match "glob" -result "application/postscript*" test ns_guesstype-6.91 {basic operation: ns_guesstype with extension .pub} -body { ns_guesstype "filename.pub" } -match "glob" -result "application/x-mspubllisher*" test ns_guesstype-6.92 {basic operation: ns_guesstype with extension .qt} -body { ns_guesstype "filename.qt" } -match "glob" -result "video/quicktime*" test ns_guesstype-6.93 {basic operation: ns_guesstype with extension .ra} -body { ns_guesstype "filename.ra" } -match "glob" -result "audio/x-pn-realaudio*" test ns_guesstype-6.94 {basic operation: ns_guesstype with extension .ram} -body { ns_guesstype "filename.ram" } -match "glob" -result "audio/x-pn-realaudio*" test ns_guesstype-6.95 {basic operation: ns_guesstype with extension .ras} -body { ns_guesstype "filename.ras" } -match "glob" -result "image/x-cmu-raster*" test ns_guesstype-6.96 {basic operation: ns_guesstype with extension .rdf} -body { ns_guesstype "filename.rdf" } -match "glob" -result "application/rdf+xml*" test ns_guesstype-6.97 {basic operation: ns_guesstype with extension .rgb} -body { ns_guesstype "filename.rgb" } -match "glob" -result "image/x-rgb*" test ns_guesstype-6.98 {basic operation: ns_guesstype with extension .rtf} -body { ns_guesstype "filename.rtf" } -match "glob" -result "text/rtf*" test ns_guesstype-6.99 {basic operation: ns_guesstype with extension .rtx} -body { ns_guesstype "filename.rtx" } -match "glob" -result "text/richtext*" test ns_guesstype-6.100 {basic operation: ns_guesstype with extension .rss} -body { ns_guesstype "filename.rss" } -match "glob" -result "application/rss+xml*" test ns_guesstype-6.101 {basic operation: ns_guesstype with extension .sit} -body { ns_guesstype "filename.sit" } -match "glob" -result "application/x-stuffit*" test ns_guesstype-6.102 {basic operation: ns_guesstype with extension .smi} -body { ns_guesstype "filename.smi" } -match "glob" -result "application/smil*" test ns_guesstype-6.103 {basic operation: ns_guesstype with extension .smil} -body { ns_guesstype "filename.smil" } -match "glob" -result "application/smil*" test ns_guesstype-6.104 {basic operation: ns_guesstype with extension .snd} -body { ns_guesstype "filename.snd" } -match "glob" -result "audio/basic*" test ns_guesstype-6.105 {basic operation: ns_guesstype with extension .spx} -body { ns_guesstype "filename.spx" } -match "glob" -result "application/ogg*" test ns_guesstype-6.106 {basic operation: ns_guesstype with extension .sql} -body { ns_guesstype "filename.sql" } -match "glob" -result "application/x-sql*" test ns_guesstype-6.107 {basic operation: ns_guesstype with extension .stc} -body { ns_guesstype "filename.stc" } -match "glob" -result "application/vnd.sun.xml.calc.template*" cleanupTests --- NEW FILE: ns_httptime.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_httptime.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # package require tcltest 2.2 namespace import -force ::tcltest::* eval ::tcltest::configure $argv if {[ns_httptime 0] eq "Thu, 01 Jan 1970 00:00:00 GMT"} { testConstraint correctLocale true } test ns_httptime-1.1 {basic syntax: plain call} -body { ns_httptime } -constraints correctLocale -returnCodes error -result {wrong # args: should be "ns_httptime time"} test ns_httptime-1.2 {basic syntax: wrong arg type} -body { ns_httptime a } -constraints correctLocale -returnCodes error -result {expected integer but got "a"} test ns_httptime-1.3 {basic syntax: wrong number of args} -body { ns_httptime 1 2 } -constraints correctLocale -returnCodes error -result {wrong # args: should be "ns_httptime time"} test ns_httptime-2.1 {basic operation} -body { ns_httptime 0 } -constraints correctLocale -result {Thu, 01 Jan 1970 00:00:00 GMT} test ns_httptime-2.2 {basic operation} -body { ns_httptime 1 } -constraints correctLocale -result {Thu, 01 Jan 1970 00:00:01 GMT} test ns_httptime-2.3 {basic operation} -body { ns_httptime -1 } -constraints correctLocale -result {Wed, 31 Dec 1969 23:59:59 GMT} test ns_httptime-2.4 {basic operation} -body { ns_httptime 1129794520 } -constraints correctLocale -result {Thu, 20 Oct 2005 07:48:40 GMT} cleanupTests --- NEW FILE: ns_gifsize.test --- # # $Header: /cvsroot/naviserver/naviserver/tests/ns_gifsize.test,v 1.1 2005/10/20 17:02:45 eide Exp $ # # Thanks to Michael P. Lex (Kinetiqa) # package require tcltest 2.2 namespace import -force ::tcltest::* set home [ns_config test home] if {[file exists "${home}/images/empty.gif"] && [file readable "${home}/images/empty.gif"]} { testConstraint fileExistsEmpty true } if {[file exists "${home}/images/broken.gif"] && [file readable "${home}/images/broken.gif"]} { testConstraint fileExistsBroken true } if {[file exists "${home}/images/color5x200.gif"] && [file readable "${home}/images/color5x200.gif"]} { testConstraint fileExistsIndexed true } if {[file exists "${home}/images/small.gif"] && [file readable "${home}/images/small.gif"]} { testConstraint fileExistsSmall true } test ns_gifsize-1.1 {syntax} -body { ns_gifsize } -returnCodes error -result {wrong # args: should be "ns_gifsize gif_file"} test ns_gifsize-2.1 {file does not exist} -body { ns_gifsize "${home}/images/noexist.gif" } -returnCodes error -match "glob" -result {couldn't open "*": no such file or directory} test ns_gifsize-2.2 {file is empty} -constraints fileExistsEmpty -body { ns_gifsize "${home}/images/empty.gif" } -returnCodes error -match "glob" -result {could not read "*": *} test ns_gifsize-2.3 {file is broken} -constraints fileExistsBroken -body { ns_gifsize "${home}/images/broken.gif" } -returnCodes error -match "glob" -result {bad gif file*} test ns_gifsize-2.4 {normal indexed gif} -constraints fileExistsIndexed -body { ns_gifsize "${home}/images/color5x200.gif" } -result [list 5 200] test ns_gifsize-2.5 {small gif} -constraints fileExistsSmall -body { ns_gifsize "${home}/images/small.gif" } -result [list 1 1] cleanupTests |
From: Bernd E. <ei...@us...> - 2005-10-20 17:02:59
|
Update of /cvsroot/naviserver/naviserver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25378 Modified Files: ChangeLog Log Message: see ChangeLog Index: ChangeLog =================================================================== RCS file: /cvsroot/naviserver/naviserver/ChangeLog,v retrieving revision 1.221 retrieving revision 1.222 diff -C2 -d -r1.221 -r1.222 *** ChangeLog 20 Oct 2005 16:41:35 -0000 1.221 --- ChangeLog 20 Oct 2005 17:02:45 -0000 1.222 *************** *** 1,2 **** --- 1,18 ---- + 2005-10-20 Bernd Eidenschink <ei...@us...> + + * tests/ns_conn.test: + * tests/ns_crypt.test: + * tests/ns_env.test: + * tests/ns_gifsize.test: + * tests/ns_jpegsize.test: + * tests/ns_httptime.test: + * tests/ns_info.test: + * tests/ns_mime.test: + * tests/ns_sha1.test: various new tests, some to be + improved over time (especially ns_info) + * tests/images/: some gif and jpeg files for the + image tests + + 2005-10-20 Zoran Vasiljevic <vas...@us...> |
Update of /cvsroot/naviserver/naviserver/tests/images In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25378/tests/images Added Files: broken.gif color5x200.gif empty.gif small.gif broken.jpg color5x200.jpg color5x200_progressive.jpg empty.jpg Log Message: see ChangeLog --- NEW FILE: color5x200.jpg --- (This appears to be a binary file; contents omitted.) --- NEW FILE: color5x200_progressive.jpg --- (This appears to be a binary file; contents omitted.) --- NEW FILE: small.gif --- (This appears to be a binary file; contents omitted.) --- NEW FILE: color5x200.gif --- (This appears to be a binary file; contents omitted.) --- NEW FILE: empty.jpg --- --- NEW FILE: empty.gif --- --- NEW FILE: broken.gif --- (This appears to be a binary file; contents omitted.) --- NEW FILE: broken.jpg --- (This appears to be a binary file; contents omitted.) |
From: Zoran V. <vas...@us...> - 2005-10-20 16:50:56
|
Update of /cvsroot/naviserver/naviserver/nsd In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21973/nsd Modified Files: callbacks.c Log Message: Untabified, indented... Index: callbacks.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nsd/callbacks.c,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** callbacks.c 20 Oct 2005 16:41:36 -0000 1.3 --- callbacks.c 20 Oct 2005 16:50:44 -0000 1.4 *************** *** 1,7 **** /* ! * The contents of this file are subject to the AOLserver Public License * Version 1.1 (the "License"); you may not use this file except in * compliance with the License. You may obtain a copy of the License at ! * http://aolserver.lcs.mit.edu/. * * Software distributed under the License is distributed on an "AS IS" --- 1,7 ---- /* ! * The contents of this file are subject to the Mozilla Public License * Version 1.1 (the "License"); you may not use this file except in * compliance with the License. You may obtain a copy of the License at ! * http://mozilla.org/. * * Software distributed under the License is distributed on an "AS IS" *************** *** 31,38 **** * callbacks.c -- * ! * Support for Callbacks * ! * These functions allow the registration of callbacks ! * that are run at various points during the server's execution. */ --- 31,38 ---- * callbacks.c -- * ! * Support for Callbacks * ! * These functions allow the registration of callbacks ! * that are run at various points during the server's execution. */ *************** *** 57,64 **** static Ns_ThreadProc RunThread; ! static void RunCallbacks(Callback *firstPtr, int reverse); ! static void RunStart(Callback **firstPtrPtr, Ns_Thread *threadPtr); ! static void RunWait(Callback **firstPtrPtr, Ns_Thread *threadPtr, Ns_Time *toPtr); ! static void *RegisterAt(Callback **firstPtrPtr, Ns_Callback *proc, void *arg); /* --- 57,65 ---- static Ns_ThreadProc RunThread; ! ! static void RunCallbacks(Callback *firstPtr, int reverse); ! static void RunStart(Callback **firstPtrPtr, Ns_Thread *threadPtr); ! static void *RegisterAt(Callback **firstPtrPtr, Ns_Callback *proc, void *arg); ! static void RunWait(Callback **firstPtrPtr, Ns_Thread *threadPtr, Ns_Time *toPtr); /* *************** *** 75,79 **** static Ns_Mutex lock; static Ns_Cond cond; ! static int shutdownPending; static Ns_Thread serverShutdownThread; --- 76,80 ---- static Ns_Mutex lock; static Ns_Cond cond; ! static int shutdownPending; static Ns_Thread serverShutdownThread; *************** *** 96,106 **** * Ns_RegisterAtStartup -- * ! * Register a callback to run at server startup * * Results: ! * None * * Side effects: ! * The callback will be registered * *---------------------------------------------------------------------- --- 97,107 ---- * Ns_RegisterAtStartup -- * ! * Register a callback to run at server startup * * Results: ! * None * * Side effects: ! * The callback will be registered * *---------------------------------------------------------------------- *************** *** 119,129 **** * Ns_RegisterAtPreStartup -- * ! * Register a callback to run at pre-server startup * * Results: ! * None * * Side effects: ! * The callback will be registered * *---------------------------------------------------------------------- --- 120,130 ---- * Ns_RegisterAtPreStartup -- * ! * Register a callback to run at pre-server startup * * Results: ! * None * * Side effects: ! * The callback will be registered * *---------------------------------------------------------------------- *************** *** 142,152 **** * Ns_RegisterAtSignal -- * ! * Register a callback to run when a signal arrives * * Results: ! * None * * Side effects: ! * The callback will be registered * *---------------------------------------------------------------------- --- 143,153 ---- * Ns_RegisterAtSignal -- * ! * Register a callback to run when a signal arrives * * Results: ! * None * * Side effects: ! * The callback will be registered * *---------------------------------------------------------------------- *************** *** 165,177 **** * Ns_RegisterAtServerShutdown -- * ! * Register a callback to run at server shutdown. This is ! * identical to Ns_RegisterShutdown and only exists for ! * historical reasons. * * Results: ! * None. * * Side effects: ! * The callback will be registered * *---------------------------------------------------------------------- --- 166,178 ---- * Ns_RegisterAtServerShutdown -- * ! * Register a callback to run at server shutdown. This is ! * identical to Ns_RegisterShutdown and only exists for ! * historical reasons. * * Results: ! * None. * * Side effects: ! * The callback will be registered * *---------------------------------------------------------------------- *************** *** 196,206 **** * Ns_RegisterAtShutdown -- * ! * Register a callback to run at server shutdown. * * Results: ! * None. * * Side effects: ! * The callback will be registered. * *---------------------------------------------------------------------- --- 197,207 ---- * Ns_RegisterAtShutdown -- * ! * Register a callback to run at server shutdown. * * Results: ! * None. * * Side effects: ! * The callback will be registered. * *---------------------------------------------------------------------- *************** *** 219,223 **** } - /* --- 220,223 ---- *************** *** 226,236 **** * Ns_RegisterAtExit -- * ! * Register a callback to be run at server exit. * * Results: ! * None. * * Side effects: ! * The callback will be registerd. * *---------------------------------------------------------------------- --- 226,236 ---- * Ns_RegisterAtExit -- * ! * Register a callback to be run at server exit. * * Results: ! * None. * * Side effects: ! * The callback will be registered. * *---------------------------------------------------------------------- *************** *** 249,259 **** * NsRunStartupProcs -- * ! * Run any callbacks registered for server startup. * * Results: ! * None. * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- --- 249,259 ---- * NsRunStartupProcs -- * ! * Run any callbacks registered for server startup. * * Results: ! * None. * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- *************** *** 272,282 **** * NsRunPreStartupProcs -- * ! * Run any callbacks registered for pre-server startup. * * Results: ! * None. * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- --- 272,282 ---- * NsRunPreStartupProcs -- * ! * Run any callbacks registered for pre-server startup. * * Results: ! * None. * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- *************** *** 295,305 **** * NsRunSignalProcs -- * ! * Run any callbacks registered for when a signal arrives * * Results: ! * None. * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- --- 295,305 ---- * NsRunSignalProcs -- * ! * Run any callbacks registered for when a signal arrives * * Results: ! * None. * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- *************** *** 318,329 **** * NsRunExitProcs -- * ! * Run any callbacks registered for server startup, then ! * shutdown, then exit. * * Results: ! * None. * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- --- 318,329 ---- * NsRunExitProcs -- * ! * Run any callbacks registered for server startup, then ! * shutdown, then exit. * * Results: ! * None. * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- *************** *** 336,339 **** --- 336,340 ---- shutdownPending = 1; Ns_MutexUnlock(&lock); + RunStart(&firstServerShutdown, &serverShutdownThread); } *************** *** 361,371 **** * RegisterAt -- * ! * A generic function that registers callbacks for any event * * Results: ! * A pointer to the newly-allocated Callback structure * * Side effects: ! * A Callback struct will be alloacated and put in the linked list. * *---------------------------------------------------------------------- --- 362,372 ---- * RegisterAt -- * ! * Generic function that registers callbacks for any event * * Results: ! * Pointer to the newly-allocated Callback structure * * Side effects: ! * Callback struct will be alloacated and put in the linked list. * *---------------------------------------------------------------------- *************** *** 375,379 **** RegisterAt(Callback **firstPtrPtr, Ns_Callback *proc, void *arg) { ! Callback *cbPtr; static int first = 1; --- 376,380 ---- RegisterAt(Callback **firstPtrPtr, Ns_Callback *proc, void *arg) { ! Callback *cbPtr; static int first = 1; *************** *** 387,391 **** } if (shutdownPending) { ! ns_free(cbPtr); cbPtr = NULL; } else if (*firstPtrPtr == NULL) { --- 388,392 ---- } if (shutdownPending) { ! ns_free(cbPtr); cbPtr = NULL; } else if (*firstPtrPtr == NULL) { *************** *** 400,403 **** --- 401,405 ---- } Ns_MutexUnlock(&lock); + return (void *) cbPtr; } *************** *** 409,419 **** * RunCallbacks -- * ! * Run all callbacks in the passed-in linked list. * * Results: ! * None * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- --- 411,421 ---- * RunCallbacks -- * ! * Run all callbacks in the passed-in linked list. * * Results: ! * None * * Side effects: ! * Callbacks called back. * *---------------------------------------------------------------------- *************** *** 444,450 **** Ns_MutexLock(&lock); if (*firstPtrPtr != NULL) { ! Ns_ThreadCreate(RunThread, firstPtrPtr, 0, threadPtr); } else { ! *threadPtr = NULL; } Ns_MutexUnlock(&lock); --- 446,452 ---- Ns_MutexLock(&lock); if (*firstPtrPtr != NULL) { ! Ns_ThreadCreate(RunThread, firstPtrPtr, 0, threadPtr); } else { ! *threadPtr = NULL; } Ns_MutexUnlock(&lock); *************** *** 460,470 **** Ns_MutexLock(&lock); while (status == NS_OK && *firstPtrPtr != NULL) { ! status = Ns_CondTimedWait(&cond, &lock, toPtr); } Ns_MutexUnlock(&lock); if (status != NS_OK) { ! Ns_Log(Warning, "callbacks: timeout waiting for shutdown procs"); } else if (*threadPtr != NULL) { ! Ns_ThreadJoin(threadPtr, NULL); } } --- 462,472 ---- Ns_MutexLock(&lock); while (status == NS_OK && *firstPtrPtr != NULL) { ! status = Ns_CondTimedWait(&cond, &lock, toPtr); } Ns_MutexUnlock(&lock); if (status != NS_OK) { ! Ns_Log(Warning, "callbacks: timeout waiting for shutdown procs"); } else if (*threadPtr != NULL) { ! Ns_ThreadJoin(threadPtr, NULL); } } *************** *** 486,492 **** Ns_MutexLock(&lock); while (*firstPtrPtr != NULL) { ! firstPtr = *firstPtrPtr; ! *firstPtrPtr = firstPtr->nextPtr; ! ns_free(firstPtr); } Ns_CondSignal(&cond); --- 488,494 ---- Ns_MutexLock(&lock); while (*firstPtrPtr != NULL) { ! firstPtr = *firstPtrPtr; ! *firstPtrPtr = firstPtr->nextPtr; ! ns_free(firstPtr); } Ns_CondSignal(&cond); *************** *** 494,498 **** } - static void AppendList(Tcl_DString *dsPtr, char *list, Callback *firstPtr, int reverse) --- 496,499 ---- |
From: Bernd E. <ei...@us...> - 2005-10-20 16:48:00
|
Update of /cvsroot/naviserver/naviserver/tests/images In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21244/images Log Message: Directory /cvsroot/naviserver/naviserver/tests/images added to the repository |
From: Zoran V. <vas...@us...> - 2005-10-20 16:41:44
|
Update of /cvsroot/naviserver/naviserver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19692 Modified Files: ChangeLog Log Message: Added options to run registered callbacks in both FIFO and LIFO fashion. All of the start-type callbacks are now executed in FIFO and all stop-type in LIFO. Index: ChangeLog =================================================================== RCS file: /cvsroot/naviserver/naviserver/ChangeLog,v retrieving revision 1.220 retrieving revision 1.221 diff -C2 -d -r1.220 -r1.221 *** ChangeLog 20 Oct 2005 15:03:50 -0000 1.220 --- ChangeLog 20 Oct 2005 16:41:35 -0000 1.221 *************** *** 1,2 **** --- 1,8 ---- + 2005-10-20 Zoran Vasiljevic <vas...@us...> + + * nsd/callbacks.c: added options to run registered callbacks + in both FIFO and LIFO fashion. All of the start-type callbacks + are now executed in FIFO and all stop-type in LIFO. + 2005-10-20 Vlad Seryakov <ser...@us...> |
From: Zoran V. <vas...@us...> - 2005-10-20 16:41:44
|
Update of /cvsroot/naviserver/naviserver/nsd In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19692/nsd Modified Files: callbacks.c Log Message: Added options to run registered callbacks in both FIFO and LIFO fashion. All of the start-type callbacks are now executed in FIFO and all stop-type in LIFO. Index: callbacks.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nsd/callbacks.c,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** callbacks.c 10 Jun 2005 17:58:38 -0000 1.2 --- callbacks.c 20 Oct 2005 16:41:36 -0000 1.3 *************** *** 47,50 **** --- 47,51 ---- typedef struct Callback { struct Callback *nextPtr; + struct Callback *prevPtr; Ns_Callback *proc; void *arg; *************** *** 56,60 **** static Ns_ThreadProc RunThread; ! static void RunCallbacks(Callback *firstPtr); static void RunStart(Callback **firstPtrPtr, Ns_Thread *threadPtr); static void RunWait(Callback **firstPtrPtr, Ns_Thread *threadPtr, Ns_Time *toPtr); --- 57,61 ---- static Ns_ThreadProc RunThread; ! static void RunCallbacks(Callback *firstPtr, int reverse); static void RunStart(Callback **firstPtrPtr, Ns_Thread *threadPtr); static void RunWait(Callback **firstPtrPtr, Ns_Thread *threadPtr, Ns_Time *toPtr); *************** *** 86,90 **** NsRunAtReadyProcs(void) { ! RunCallbacks(firstReady); } --- 87,91 ---- NsRunAtReadyProcs(void) { ! RunCallbacks(firstReady, 0); } *************** *** 262,266 **** NsRunStartupProcs(void) { ! RunCallbacks(firstStartup); } --- 263,267 ---- NsRunStartupProcs(void) { ! RunCallbacks(firstStartup, 1); } *************** *** 285,289 **** NsRunPreStartupProcs(void) { ! RunCallbacks(firstPreStartup); } --- 286,290 ---- NsRunPreStartupProcs(void) { ! RunCallbacks(firstPreStartup, 1); } *************** *** 308,312 **** NsRunSignalProcs(void) { ! RunCallbacks(firstSignal); } --- 309,313 ---- NsRunSignalProcs(void) { ! RunCallbacks(firstSignal, 1); } *************** *** 351,355 **** NsRunAtExitProcs(void) { ! RunCallbacks(firstExit); } --- 352,356 ---- NsRunAtExitProcs(void) { ! RunCallbacks(firstExit, 0); } *************** *** 382,394 **** Ns_MutexLock(&lock); if (first) { ! Ns_MutexSetName(&lock, "ns:callbacks"); ! first = 0; } if (shutdownPending) { ns_free(cbPtr); ! cbPtr = NULL; } else { ! cbPtr->nextPtr = *firstPtrPtr; ! *firstPtrPtr = cbPtr; } Ns_MutexUnlock(&lock); --- 383,401 ---- Ns_MutexLock(&lock); if (first) { ! Ns_MutexSetName(&lock, "ns:callbacks"); ! first = 0; } if (shutdownPending) { ns_free(cbPtr); ! cbPtr = NULL; ! } else if (*firstPtrPtr == NULL) { ! *firstPtrPtr = cbPtr; ! cbPtr->nextPtr = NULL; ! cbPtr->prevPtr = NULL; } else { ! (*firstPtrPtr)->prevPtr = cbPtr; ! cbPtr->nextPtr = *firstPtrPtr; ! cbPtr->prevPtr = NULL; ! *firstPtrPtr = cbPtr; } Ns_MutexUnlock(&lock); *************** *** 402,406 **** * RunCallbacks -- * ! * Run all callbacks in the passed-in linked list * * Results: --- 409,413 ---- * RunCallbacks -- * ! * Run all callbacks in the passed-in linked list. * * Results: *************** *** 414,422 **** static void ! RunCallbacks(Callback *cbPtr) { while (cbPtr != NULL) { (*cbPtr->proc) (cbPtr->arg); ! cbPtr = cbPtr->nextPtr; } } --- 421,439 ---- static void ! RunCallbacks(Callback *cbPtr, int reverse) { + if (reverse) { + while (cbPtr != NULL && cbPtr->nextPtr != NULL) { + cbPtr = cbPtr->nextPtr; + } + } + while (cbPtr != NULL) { (*cbPtr->proc) (cbPtr->arg); ! if (reverse) { ! cbPtr = cbPtr->prevPtr; ! } else { ! cbPtr = cbPtr->nextPtr; ! } } } *************** *** 465,469 **** Ns_MutexUnlock(&lock); ! RunCallbacks(firstPtr); Ns_MutexLock(&lock); --- 482,486 ---- Ns_MutexUnlock(&lock); ! RunCallbacks(firstPtr, 0); Ns_MutexLock(&lock); *************** *** 479,493 **** static void ! AppendList(Tcl_DString *dsPtr, char *list, Callback *firstPtr) { ! Callback *cbPtr; - cbPtr = firstPtr; while (cbPtr != NULL) { ! Tcl_DStringStartSublist(dsPtr); ! Tcl_DStringAppendElement(dsPtr, list); ! Ns_GetProcInfo(dsPtr, (void *) cbPtr->proc, cbPtr->arg); ! Tcl_DStringEndSublist(dsPtr); ! cbPtr = cbPtr->nextPtr; } } --- 496,519 ---- static void ! AppendList(Tcl_DString *dsPtr, char *list, Callback *firstPtr, int reverse) { ! Callback *cbPtr = firstPtr; ! ! if (reverse) { ! while (cbPtr != NULL && cbPtr->nextPtr != NULL) { ! cbPtr = cbPtr->nextPtr; ! } ! } while (cbPtr != NULL) { ! Tcl_DStringStartSublist(dsPtr); ! Tcl_DStringAppendElement(dsPtr, list); ! Ns_GetProcInfo(dsPtr, (void *) cbPtr->proc, cbPtr->arg); ! Tcl_DStringEndSublist(dsPtr); ! if (reverse) { ! cbPtr = cbPtr->prevPtr; ! } else { ! cbPtr = cbPtr->nextPtr; ! } } } *************** *** 498,507 **** { Ns_MutexLock(&lock); ! AppendList(dsPtr, "prestartup", firstPreStartup); ! AppendList(dsPtr, "startup", firstStartup); ! AppendList(dsPtr, "signal", firstSignal); ! AppendList(dsPtr, "servershutdown", firstServerShutdown); ! AppendList(dsPtr, "shutdown", firstShutdown); ! AppendList(dsPtr, "exit", firstExit); Ns_MutexUnlock(&lock); } --- 524,533 ---- { Ns_MutexLock(&lock); ! AppendList(dsPtr, "prestartup", firstPreStartup, 1); ! AppendList(dsPtr, "startup", firstStartup, 1); ! AppendList(dsPtr, "signal", firstSignal, 1); ! AppendList(dsPtr, "servershutdown", firstServerShutdown, 0); ! AppendList(dsPtr, "shutdown", firstShutdown, 0); ! AppendList(dsPtr, "exit", firstExit, 0); Ns_MutexUnlock(&lock); } |
From: Vlad S. <ser...@us...> - 2005-10-20 15:04:01
|
Update of /cvsroot/naviserver/naviserver/nsd In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27188/nsd Modified Files: tclmisc.c uuencode.c Log Message: fixed bug with ns_uuencode and 1 byte string Index: tclmisc.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nsd/tclmisc.c,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** tclmisc.c 9 Oct 2005 22:27:24 -0000 1.13 --- tclmisc.c 20 Oct 2005 15:03:50 -0000 1.14 *************** *** 455,459 **** } string = Tcl_GetStringFromObj(objv[1], &nbytes); ! result = ns_malloc((size_t) 1 + (4 * nbytes) / 2); Ns_HtuuEncode((unsigned char *) string, (size_t)nbytes, result); Tcl_SetResult(interp, result, (Tcl_FreeProc *) ns_free); --- 455,459 ---- } string = Tcl_GetStringFromObj(objv[1], &nbytes); ! result = ns_malloc((size_t) 1 + (4 * MAX(nbytes,2)) / 2); Ns_HtuuEncode((unsigned char *) string, (size_t)nbytes, result); Tcl_SetResult(interp, result, (Tcl_FreeProc *) ns_free); Index: uuencode.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nsd/uuencode.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** uuencode.c 13 Jun 2005 06:14:26 -0000 1.4 --- uuencode.c 20 Oct 2005 15:03:50 -0000 1.5 *************** *** 94,98 **** * Encoded characters are placed in output which must be * large enough for the result, i.e., (1 + (len * 4) / 2) ! * bytes. * *---------------------------------------------------------------------- --- 94,98 ---- * Encoded characters are placed in output which must be * large enough for the result, i.e., (1 + (len * 4) / 2) ! * bytes, minimum outout buffer size is 4 bytes. * *---------------------------------------------------------------------- |
From: Vlad S. <ser...@us...> - 2005-10-20 15:04:01
|
Update of /cvsroot/naviserver/naviserver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27188 Modified Files: ChangeLog Log Message: fixed bug with ns_uuencode and 1 byte string Index: ChangeLog =================================================================== RCS file: /cvsroot/naviserver/naviserver/ChangeLog,v retrieving revision 1.219 retrieving revision 1.220 diff -C2 -d -r1.219 -r1.220 *** ChangeLog 19 Oct 2005 13:26:34 -0000 1.219 --- ChangeLog 20 Oct 2005 15:03:50 -0000 1.220 *************** *** 1,2 **** --- 1,9 ---- + 2005-10-20 Vlad Seryakov <ser...@us...> + + * nsd/tclmisc.c: + * nsd/uuencode.c: + * test/ns_uuencode.test: fixed bug that causes nsd to segfault if + called ns_uuencode with 1 byte string + 2005-10-19 Zoran Vasiljevic <vas...@us...> |
From: Vlad S. <ser...@us...> - 2005-10-20 15:04:00
|
Update of /cvsroot/naviserver/naviserver/tests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27188/tests Added Files: ns_uuencode.test Log Message: fixed bug with ns_uuencode and 1 byte string --- NEW FILE: ns_uuencode.test --- # # The contents of this file are subject to the AOLserver Public License # Version 1.1 (the "License"); you may not use this file except in # compliance with the License. You may obtain a copy of the License at # http://aolserver.com/. # # Software distributed under the License is distributed on an "AS IS" # basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See # the License for the specific language governing rights and limitations # under the License. # # The Original Code is AOLserver Code and related documentation # distributed by AOL. # # The Initial Developer of the Original Code is America Online, # Inc. Portions created by AOL are Copyright (C) 1999 America Online, # Inc. All Rights Reserved. # # Alternatively, the contents of this file may be used under the terms # of the GNU General Public License (the "GPL"), in which case the # provisions of GPL are applicable instead of those above. If you wish # to allow use of your version of this file only under the terms of the # GPL and not to allow others to use your version of this file under the # License, indicate your decision by deleting the provisions above and # replace them with the notice and other provisions required by the GPL. # If you do not delete the provisions above, a recipient may use your # version of this file under either the License or the GPL. # # # $Header: /cvsroot/naviserver/naviserver/tests/ns_uuencode.test,v 1.1 2005/10/20 15:03:50 seryakov Exp $ # package require tcltest 2.2 namespace import -force ::tcltest::* test ns_uuencode-1.1 {long string} -body { ns_uuencode 1234567890 } -result MTIzNDU2Nzg5MA== test ns_uuencode-1.2 {short string} -body { ns_uuencode @ } -result QA== test ns_uudecode-2.1 {encoded string} -body { ns_uudecode MTIzNDU2Nzg5MA== } -result 1234567890 cleanupTests |
From: Zoran V. <vas...@us...> - 2005-10-19 13:26:47
|
Update of /cvsroot/naviserver/naviserver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10675 Modified Files: ChangeLog Log Message: See file. Index: ChangeLog =================================================================== RCS file: /cvsroot/naviserver/naviserver/ChangeLog,v retrieving revision 1.218 retrieving revision 1.219 diff -C2 -d -r1.218 -r1.219 *** ChangeLog 17 Oct 2005 11:43:58 -0000 1.218 --- ChangeLog 19 Oct 2005 13:26:34 -0000 1.219 *************** *** 1,5 **** 2005-10-17 Zoran Vasiljevic <vas...@us...> ! * nsdlog/nslog.c: missed initialization of logfile descriptor. This caused us to close invalid descriptor in LogOpen. As the result, the interactive NS mode assumed non-interactive use and --- 1,10 ---- + 2005-10-19 Zoran Vasiljevic <vas...@us...> + + * nslog/nslog.c (Ns_ModuleInit): failed to create the log + file when given the relative path. + 2005-10-17 Zoran Vasiljevic <vas...@us...> ! * nslog/nslog.c: missed initialization of logfile descriptor. This caused us to close invalid descriptor in LogOpen. As the result, the interactive NS mode assumed non-interactive use and |
From: Zoran V. <vas...@us...> - 2005-10-19 13:25:28
|
Update of /cvsroot/naviserver/naviserver/nslog In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv9912 Modified Files: nslog.c Log Message: Ns_ModuleInit failed to create the log file if given relative path to the file. Index: nslog.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nslog/nslog.c,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** nslog.c 17 Oct 2005 11:28:21 -0000 1.13 --- nslog.c 19 Oct 2005 13:25:17 -0000 1.14 *************** *** 203,213 **** logPtr->file = ns_strdup(file); } else { /* * If log file is not given in absolute format, it's expected to ! * exist in the module specific directory, which is created if necessary. */ - Tcl_Obj *dirpath; Ns_ModulePath(&ds, server, module, NULL, NULL); dirpath = Tcl_NewStringObj(ds.string, -1); --- 203,214 ---- logPtr->file = ns_strdup(file); } else { + Tcl_Obj *dirpath; /* * If log file is not given in absolute format, it's expected to ! * exist in the module specific directory, which is created if ! * necessary. */ Ns_ModulePath(&ds, server, module, NULL, NULL); dirpath = Tcl_NewStringObj(ds.string, -1); *************** *** 222,226 **** } Ns_DStringTrunc(&ds, 0); ! Ns_ModulePath(&ds, server, module, logPtr->file, NULL); logPtr->file = Ns_DStringExport(&ds); } --- 223,227 ---- } Ns_DStringTrunc(&ds, 0); ! Ns_ModulePath(&ds, server, module, file, NULL); logPtr->file = Ns_DStringExport(&ds); } |
From: Stephen D. <sd...@us...> - 2005-10-17 11:44:14
|
Update of /cvsroot/naviserver/naviserver/tests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14198/tests Modified Files: ns_log.test Log Message: * nsd/log.c: * tests/ns_log.test: Add new sub-command: ns_logctl severity. With this you can query and set the status of any of the log levels at runtime. For example, you could log into the control port -- ns_logctl severity debug on -- to track down a problem. Index: ns_log.test =================================================================== RCS file: /cvsroot/naviserver/naviserver/tests/ns_log.test,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ns_log.test 4 Aug 2005 05:29:41 -0000 1.1 --- ns_log.test 17 Oct 2005 11:43:58 -0000 1.2 *************** *** 27,35 **** test ns_log-2.2 {basic syntax} -body { ns_logctl ? ! } -returnCodes error -result {bad option "?": must be hold, count, get, peek, flush, release, or truncate} ns_logctl hold ns_logctl trunc test ns_log-3.1 {severity} -body { --- 27,37 ---- test ns_log-2.2 {basic syntax} -body { ns_logctl ? ! } -returnCodes error -result {bad option "?": must be hold, count, get, peek, flush, release, truncate, or severity} ns_logctl hold ns_logctl trunc + ns_logctl severity debug on + ns_logctl severity dev on test ns_log-3.1 {severity} -body { *************** *** 58,67 **** } -match glob -result "* Bug: test\n" ! test ns_log-3.6 {severity} -constraints knownBug -body { ns_log debug test ns_logctl get } -match glob -result "* Debug: test\n" ! test ns_log-3.7 {severity} -constraints knownBug -body { ns_log dev test ns_logctl get --- 60,69 ---- } -match glob -result "* Bug: test\n" ! test ns_log-3.6 {severity} -body { ns_log debug test ns_logctl get } -match glob -result "* Debug: test\n" ! test ns_log-3.7 {severity} -body { ns_log dev test ns_logctl get *************** *** 143,148 **** --- 145,175 ---- + test ns_log-6.1 {configuration} -body { + ns_logctl severity + } -returnCodes error -result {wrong # args: should be "ns_logctl severity severity-level ?bool?"} + + test ns_log-6.2 {configuration} -body { + ns_logctl severity ? + } -returnCodes error -result {bad severity "?": must be notice, Notice, warning, Warning, error, Error, fatal, Fatal, bug, Bug, debug, Debug, dev, or Dev} + + test ns_log-6.3 {configuration} -body { + ns_logctl severity debug + } -result 1 + + test ns_log-6.4 {configuration} -body { + ns_logctl severity debug 0 + } -result 0 + + test ns_log-6.5 {configuration} -body { + ns_logctl severity debug + } -result 0 + + + ns_logctl trunc ns_logctl release + ns_logctl severity debug off + ns_logctl severity dev off + cleanupTests |
From: Stephen D. <sd...@us...> - 2005-10-17 11:44:14
|
Update of /cvsroot/naviserver/naviserver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14198 Modified Files: ChangeLog Log Message: * nsd/log.c: * tests/ns_log.test: Add new sub-command: ns_logctl severity. With this you can query and set the status of any of the log levels at runtime. For example, you could log into the control port -- ns_logctl severity debug on -- to track down a problem. Index: ChangeLog =================================================================== RCS file: /cvsroot/naviserver/naviserver/ChangeLog,v retrieving revision 1.217 retrieving revision 1.218 diff -C2 -d -r1.217 -r1.218 *** ChangeLog 17 Oct 2005 11:30:31 -0000 1.217 --- ChangeLog 17 Oct 2005 11:43:58 -0000 1.218 *************** *** 8,11 **** --- 8,17 ---- 2005-10-17 Stephen Deasey <sd...@us...> + * nsd/log.c: + * tests/ns_log.test: Add new sub-command: ns_logctl severity. + With this you can query and set the status of any of the log + levels at runtime. For example, you could log into the control + port -- ns_logctl severity debug on -- to track down a problem. + * nslog/nslog.c: * nscp/nscp.c: |
From: Stephen D. <sd...@us...> - 2005-10-17 11:44:13
|
Update of /cvsroot/naviserver/naviserver/nsd In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14198/nsd Modified Files: log.c Log Message: * nsd/log.c: * tests/ns_log.test: Add new sub-command: ns_logctl severity. With this you can query and set the status of any of the log levels at runtime. For example, you could log into the control port -- ns_logctl severity debug on -- to track down a problem. Index: log.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nsd/log.c,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** log.c 16 Oct 2005 08:52:48 -0000 1.10 --- log.c 17 Oct 2005 11:43:58 -0000 1.11 *************** *** 92,96 **** /* ! * Keep the following in sync with the Ns_LogSeverity enum. */ --- 92,99 ---- /* ! * The following table defines which severity levels ! * are currently active. ! * ! * Be sure to keep the order in sync with the Ns_LogSeverity enum. */ *************** *** 108,111 **** --- 111,133 ---- }; + /* + * The following table converts from severity string names to + * an Ns_LogSeverity enum value. + */ + + static struct { + char *string; + Ns_LogSeverity severity; + } severityTable[] = { + {"notice", Notice}, {"Notice", Notice}, + {"warning", Warning}, {"Warning", Warning}, + {"error", Error}, {"Error", Error}, + {"fatal", Fatal}, {"Fatal", Fatal}, + {"bug", Bug}, {"Bug", Bug}, + {"debug", Debug}, {"Debug", Debug}, + {"dev", Dev}, {"Dev", Dev}, + {NULL, 0} + }; + /* *************** *** 472,485 **** Tcl_Obj *CONST objv[]) { ! LogCache *cachePtr; ! int len, opt; static CONST char *opts[] = { "hold", "count", "get", "peek", "flush", "release", ! "truncate", NULL }; enum { CHoldIdx, CCountIdx, CGetIdx, CPeekIdx, CFlushIdx, CReleaseIdx, ! CTruncIdx }; --- 494,508 ---- Tcl_Obj *CONST objv[]) { ! LogCache *cachePtr; ! int len, opt, i, bool; ! Ns_LogSeverity severity; static CONST char *opts[] = { "hold", "count", "get", "peek", "flush", "release", ! "truncate", "severity", NULL }; enum { CHoldIdx, CCountIdx, CGetIdx, CPeekIdx, CFlushIdx, CReleaseIdx, ! CTruncIdx, CSeverityIdx }; *************** *** 529,532 **** --- 552,576 ---- Ns_DStringTrunc(&cachePtr->buffer, len); break; + + case CSeverityIdx: + if (objc != 3 && objc != 4) { + Tcl_WrongNumArgs(interp, 2, objv, "severity-level ?bool?"); + return TCL_ERROR; + } + if (Tcl_GetIndexFromObjStruct(interp, objv[2], severityTable, + sizeof(severityTable[0]), "severity", + TCL_EXACT, &i) != TCL_OK) { + return TCL_ERROR; + } + severity = severityTable[i].severity; + if (objc == 4) { + if (Tcl_GetBooleanFromObj(interp, objv[3], &bool) != TCL_OK) { + return TCL_ERROR; + } + logConfig[severity].enabled = bool; + } + Tcl_SetBooleanObj(Tcl_GetObjResult(interp), + logConfig[severity].enabled); + break; } *************** *** 559,576 **** int i; - struct { - char *string; - Ns_LogSeverity severity; - } severityTable[] = { - {"notice", Notice}, {"Notice", Notice}, - {"warning", Warning}, {"Warning", Warning}, - {"error", Error}, {"Error", Error}, - {"fatal", Fatal}, {"Fatal", Fatal}, - {"bug", Bug}, {"Bug", Bug}, - {"debug", Debug}, {"Debug", Debug}, - {"dev", Dev}, {"Dev", Dev}, - {NULL, 0} - }; - if (objc < 3) { Tcl_WrongNumArgs(interp, 1, objv, "severity string ?string ...?"); --- 603,606 ---- |
From: Zoran V. <vas...@us...> - 2005-10-17 11:30:42
|
Update of /cvsroot/naviserver/naviserver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11744 Modified Files: ChangeLog Log Message: See file. Index: ChangeLog =================================================================== RCS file: /cvsroot/naviserver/naviserver/ChangeLog,v retrieving revision 1.216 retrieving revision 1.217 diff -C2 -d -r1.216 -r1.217 *** ChangeLog 17 Oct 2005 11:25:15 -0000 1.216 --- ChangeLog 17 Oct 2005 11:30:31 -0000 1.217 *************** *** 1,2 **** --- 1,9 ---- + 2005-10-17 Zoran Vasiljevic <vas...@us...> + + * nsdlog/nslog.c: missed initialization of logfile descriptor. + This caused us to close invalid descriptor in LogOpen. As the + result, the interactive NS mode assumed non-interactive use and + prematurely exited. + 2005-10-17 Stephen Deasey <sd...@us...> |
From: Zoran V. <vas...@us...> - 2005-10-17 11:28:32
|
Update of /cvsroot/naviserver/naviserver/nslog In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11364/nslog Modified Files: nslog.c Log Message: Missed initialization of logfile descriptor. This caused us to close invalid descriptor in LogOpen. As the result, the interactive NS mode assumed non-interactive use and prematurely exited. Index: nslog.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nslog/nslog.c,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** nslog.c 17 Oct 2005 11:25:17 -0000 1.12 --- nslog.c 17 Oct 2005 11:28:21 -0000 1.13 *************** *** 188,191 **** --- 188,192 ---- logPtr = ns_calloc(1,sizeof(Log)); logPtr->module = module; + logPtr->fd = -1; Ns_MutexInit(&logPtr->lock); Ns_MutexSetName2(&logPtr->lock, "nslog", server); |
From: Stephen D. <sd...@us...> - 2005-10-17 11:25:28
|
Update of /cvsroot/naviserver/naviserver/nscp In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10314/nscp Modified Files: nscp.c Log Message: * nslog/nslog.c: * nscp/nscp.c: * nscgi/nscgi.c: * nsdb/dbinit.c: Use new config routines. Index: nscp.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nscp/nscp.c,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** nscp.c 13 Jun 2005 06:14:26 -0000 1.5 --- nscp.c 17 Oct 2005 11:25:17 -0000 1.6 *************** *** 149,159 **** modPtr->addr = addr; modPtr->port = port; ! if (!Ns_ConfigGetBool(path, "echopassword", &modPtr->echo)) { ! modPtr->echo = 1; ! } ! ! if (!Ns_ConfigGetBool(path, "cpcmdlogging", &modPtr->commandLogging)) { ! modPtr->commandLogging = 0; /* Default to off */ ! } /* --- 149,154 ---- modPtr->addr = addr; modPtr->port = port; ! modPtr->echo = Ns_ConfigBool(path, "echopasswd", NS_TRUE); ! modPtr->commandLogging = Ns_ConfigBool(path, "cpcmdlogging", NS_FALSE); /* |
From: Stephen D. <sd...@us...> - 2005-10-17 11:25:28
|
Update of /cvsroot/naviserver/naviserver/nscgi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10314/nscgi Modified Files: nscgi.c Log Message: * nslog/nslog.c: * nscp/nscp.c: * nscgi/nscgi.c: * nsdb/dbinit.c: Use new config routines. Index: nscgi.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nscgi/nscgi.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** nscgi.c 30 Jul 2005 04:06:01 -0000 1.4 --- nscgi.c 17 Oct 2005 11:25:17 -0000 1.5 *************** *** 37,41 **** #define BUFSIZE 4096 #define NDSTRINGS 5 - #define DEFAULT_MAXINPUT 1024000 #define CGI_NPH 1 #define CGI_GETHOST 2 --- 37,40 ---- *************** *** 194,211 **** Ns_MutexInit(&modPtr->lock); Ns_MutexSetName2(&modPtr->lock, "nscgi", server); ! if (!Ns_ConfigGetInt(path, "maxinput", &modPtr->maxInput)) { ! modPtr->maxInput = DEFAULT_MAXINPUT; ! } ! if (!Ns_ConfigGetInt(path, "limit", &modPtr->maxCgi)) { ! modPtr->maxCgi = 0; ! } ! if (!Ns_ConfigGetInt(path, "maxwait", &modPtr->maxWait)) { ! modPtr->maxWait = 30; ! } ! if (!Ns_ConfigGetBool(path, "gethostbyaddr", &i)) { ! i = 0; ! } ! if (i) { ! modPtr->flags |= CGI_GETHOST; } --- 193,201 ---- Ns_MutexInit(&modPtr->lock); Ns_MutexSetName2(&modPtr->lock, "nscgi", server); ! modPtr->maxInput = Ns_ConfigInt(path, "maxinput", 1024000); ! modPtr->maxCgi = Ns_ConfigInt(path, "limit", 0); ! modPtr->maxWait = Ns_ConfigInt(path, "maxwait", 30); ! if (Ns_ConfigBool(path, "gethostbyaddr", NS_FALSE)) { ! modPtr->flags |= CGI_GETHOST; } *************** *** 221,225 **** if (modPtr->interps == NULL) { Ns_Log(Warning, "nscgi: no such interps section: %s", ! ds.string); } Ns_DStringTrunc(&ds, 0); --- 211,215 ---- if (modPtr->interps == NULL) { Ns_Log(Warning, "nscgi: no such interps section: %s", ! ds.string); } Ns_DStringTrunc(&ds, 0); *************** *** 231,243 **** if (modPtr->mergeEnv == NULL) { Ns_Log(Warning, "nscgi: no such environment section: %s", ! ds.string); } Ns_DStringTrunc(&ds, 0); } ! if (!Ns_ConfigGetBool(path, "systemenvironment", &i)) { ! i = 0; ! } ! if (i) { ! modPtr->flags |= CGI_SYSENV; } --- 221,230 ---- if (modPtr->mergeEnv == NULL) { Ns_Log(Warning, "nscgi: no such environment section: %s", ! ds.string); } Ns_DStringTrunc(&ds, 0); } ! if (Ns_ConfigBool(path, "systemenvironment", NS_FALSE)) { ! modPtr->flags |= CGI_SYSENV; } |
From: Stephen D. <sd...@us...> - 2005-10-17 11:25:26
|
Update of /cvsroot/naviserver/naviserver/nslog In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10314/nslog Modified Files: nslog.c Log Message: * nslog/nslog.c: * nscp/nscp.c: * nscgi/nscgi.c: * nsdb/dbinit.c: Use new config routines. Index: nslog.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nslog/nslog.c,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** nslog.c 5 Oct 2005 09:40:33 -0000 1.11 --- nslog.c 17 Oct 2005 11:25:17 -0000 1.12 *************** *** 167,173 **** Ns_ModuleInit(char *server, char *module) { ! char *path; Log *logPtr; ! int opt, hour, status; Ns_DString ds; static int first = 1; --- 167,173 ---- Ns_ModuleInit(char *server, char *module) { ! CONST char *path, *file; Log *logPtr; ! int hour, status; Ns_DString ds; static int first = 1; *************** *** 192,213 **** Ns_DStringInit(&logPtr->buffer); /* * Determine the name of the log file */ ! path = Ns_ConfigGetPath(server, module, NULL); ! logPtr->file = Ns_ConfigGetValue(path, "file"); ! if (logPtr->file == NULL) { ! logPtr->file = "access.log"; ! } ! logPtr->file = ns_strdup(logPtr->file); ! ! /* ! * If log file is not given in absolute format, it's expected to ! * exist in the module specific directory. The module directory ! * is created if necessary. ! */ - if (Ns_PathIsAbsolute(logPtr->file) == NS_FALSE) { Tcl_Obj *dirpath; Ns_ModulePath(&ds, server, module, NULL, NULL); --- 192,211 ---- Ns_DStringInit(&logPtr->buffer); + path = Ns_ConfigGetPath(server, module, NULL); + /* * Determine the name of the log file */ ! file = Ns_ConfigString(path, "file", "access.log"); ! if (Ns_PathIsAbsolute(file)) { ! logPtr->file = ns_strdup(file); ! } else { ! ! /* ! * If log file is not given in absolute format, it's expected to ! * exist in the module specific directory, which is created if necessary. ! */ Tcl_Obj *dirpath; Ns_ModulePath(&ds, server, module, NULL, NULL); *************** *** 231,258 **** */ ! logPtr->rollfmt = Ns_ConfigGetValue(path, "rollfmt"); ! if (logPtr->rollfmt != NULL) { ! logPtr->rollfmt = ns_strdup(logPtr->rollfmt); ! } ! if (!Ns_ConfigGetInt(path, "maxbackup", &logPtr->maxbackup) ! || logPtr->maxbackup < 1) { ! logPtr->maxbackup = 100; ! } ! if (!Ns_ConfigGetInt(path, "maxbuffer", &logPtr->maxlines)) { ! logPtr->maxlines = 0; ! } ! if (!Ns_ConfigGetBool(path, "formattedTime", &opt) || opt) { logPtr->flags |= LOG_FMTTIME; } ! if (!Ns_ConfigGetBool(path, "logcombined", &opt) || opt) { logPtr->flags |= LOG_COMBINED; } ! if (Ns_ConfigGetBool(path, "logreqtime", &opt) && opt) { logPtr->flags |= LOG_REQTIME; } ! if (Ns_ConfigGetBool(path, "suppressquery", &opt) && opt) { logPtr->flags |= LOG_SUPPRESSQUERY; } ! if (Ns_ConfigGetBool(path, "checkforproxy", &opt) && opt) { logPtr->flags |= LOG_CHECKFORPROXY; } --- 229,248 ---- */ ! logPtr->rollfmt = ns_strcopy(Ns_ConfigGetValue(path, "rollfmt")); ! logPtr->maxbackup = Ns_ConfigIntRange(path, "maxbackup", 100, 1, INT_MAX); ! logPtr->maxlines = Ns_ConfigIntRange(path, "maxbuffer", 0, 0, INT_MAX); ! if (Ns_ConfigBool(path, "formattedtime", NS_TRUE)) { logPtr->flags |= LOG_FMTTIME; } ! if (Ns_ConfigBool(path, "logcombined", NS_TRUE)) { logPtr->flags |= LOG_COMBINED; } ! if (Ns_ConfigBool(path, "logreqtime", NS_FALSE)) { logPtr->flags |= LOG_REQTIME; } ! if (Ns_ConfigBool(path, "suppressquery", NS_FALSE)) { logPtr->flags |= LOG_SUPPRESSQUERY; } ! if (Ns_ConfigBool(path, "checkforproxy", NS_FALSE)) { logPtr->flags |= LOG_CHECKFORPROXY; } *************** *** 262,273 **** */ ! if (!Ns_ConfigGetInt(path, "rollhour", &hour) || hour < 0 || hour > 23) { ! hour = 0; ! } ! if (!Ns_ConfigGetBool(path, "rolllog", &opt) || opt) { Ns_ScheduleDaily((Ns_SchedProc *) LogRollCallback, logPtr, 0, hour, 0, NULL); } ! if (Ns_ConfigGetBool(path, "rollonsignal", &opt) && opt) { Ns_RegisterAtSignal(LogRollCallback, logPtr); } --- 252,261 ---- */ ! if (Ns_ConfigBool(path, "rolllog", NS_TRUE)) { ! hour = Ns_ConfigIntRange(path, "rollhour", 0, 0, 23); Ns_ScheduleDaily((Ns_SchedProc *) LogRollCallback, logPtr, 0, hour, 0, NULL); } ! if (Ns_ConfigBool(path, "rollonsignal", NS_FALSE)) { Ns_RegisterAtSignal(LogRollCallback, logPtr); } |