[LON-CAPA-cvs] cvs: loncom /metadata_database searchcat.pl
www
lon-capa-cvs@mail.lon-capa.org
Wed, 08 Oct 2003 19:38:41 -0000
www Wed Oct 8 15:38:41 2003 EDT
Modified files:
/loncom/metadata_database searchcat.pl
Log:
Does what the previous one did, but uses less memory. The next version needs
to address file locking, etc., which is going to be a major change.
Index: loncom/metadata_database/searchcat.pl
diff -u loncom/metadata_database/searchcat.pl:1.42 loncom/metadata_database/searchcat.pl:1.43
--- loncom/metadata_database/searchcat.pl:1.42 Wed Oct 8 10:15:03 2003
+++ loncom/metadata_database/searchcat.pl Wed Oct 8 15:38:41 2003
@@ -2,7 +2,7 @@
# The LearningOnline Network
# searchcat.pl "Search Catalog" batch script
#
-# $Id: searchcat.pl,v 1.42 2003/10/08 14:15:03 www Exp $
+# $Id: searchcat.pl,v 1.43 2003/10/08 19:38:41 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -154,8 +154,8 @@
my $regexp=$url;
$regexp=~s/(\W)/\\$1/g;
$regexp='___'.$regexp.'___([a-z]+)$';
- while (my ($key,$value)=each %evaldata) {
- $key=&unescape($key);
+ while (my ($esckey,$value)=each %evaldata) {
+ $key=&unescape($esckey);
if ($key=~/$regexp/) {
my $ctype=$1;
if (defined($cnt{$ctype})) {
@@ -179,7 +179,7 @@
}
}
if ($ctype ne 'count') {
- $newevaldata{$_}=$value;
+ $newevaldata{$esckey}=$value;
}
}
}