Index: openacs-4/packages/acs-tcl/tcl/memoize-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/memoize-procs.tcl,v diff -u -r1.10 -r1.11 --- openacs-4/packages/acs-tcl/tcl/memoize-procs.tcl 4 Jun 2006 00:45:47 -0000 1.10 +++ openacs-4/packages/acs-tcl/tcl/memoize-procs.tcl 10 Jan 2007 21:22:12 -0000 1.11 @@ -29,15 +29,15 @@ @return The possibly-cached value returned by script. } { - if {![string equal $max_age ""] && $max_age < 0} { + if {$max_age ne "" && $max_age < 0} { error "max_age must not be negative" } set current_time [ns_time] set cached_p [ns_cache get util_memoize $script pair] - if {$cached_p && [string compare $max_age ""] != 0} { + if {$cached_p && $max_age ne "" } { set cache_time [lindex $pair 0] if {$current_time - $cache_time > $max_age} { ns_cache flush util_memoize $script @@ -99,7 +99,7 @@ return 0 } - if {[string equal $max_age ""]} { + if {$max_age eq ""} { return 1 } else { set cache_time [lindex $pair 0] @@ -129,11 +129,11 @@ } { foreach name [ns_cache names util_memoize] { - if $log_p { + if {$log_p} { ns_log Debug "util_memoize_flush_regexp: checking $name for $expr" } if { [regexp $expr $name] } { - if $log_p { + if {$log_p} { ns_log Debug "util_memoize_flush_regexp: flushing $name" } util_memoize_flush $name