Index: openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl,v diff -u -r1.25 -r1.26 --- openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl 16 Jan 2003 13:41:57 -0000 1.25 +++ openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl 21 Jan 2003 09:05:59 -0000 1.26 @@ -3018,7 +3018,25 @@ return $setid } +ad_proc -public util_sets_equal_p { list1 list2 } { + Return 1 if the two lists contain sets of identical items (strings) + (regardless of order) and 0 otherwise. + @author Peter Marklund +} { + if { [llength $list1] != [llength $list2] } { + return 0 + } + + foreach item $list1 { + if { [lsearch -exact $list2 $item] < 0 } { + return 0 + } + } + + return 1 +} + ad_proc -public util_http_file_upload { -file -data -binary:boolean -filename -name {-mime_type */*} {-mode formvars} {-rqset ""} url {formvars {}} {timeout 30}