[LON-CAPA-cvs] cvs: loncom /homework structuretags.pm

albertel lon-capa-cvs@mail.lon-capa.org
Wed, 25 Jun 2003 16:47:48 -0000


albertel		Wed Jun 25 12:47:48 2003 EDT

  Modified files:              
    /loncom/homework	structuretags.pm 
  Log:
  - make things look more random
  
  
  
Index: loncom/homework/structuretags.pm
diff -u loncom/homework/structuretags.pm:1.189 loncom/homework/structuretags.pm:1.190
--- loncom/homework/structuretags.pm:1.189	Mon Jun 23 15:55:18 2003
+++ loncom/homework/structuretags.pm	Wed Jun 25 12:47:47 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA 
 # definition of tags that give a structure to a document
 #
-# $Id: structuretags.pm,v 1.189 2003/06/23 19:55:18 sakharuk Exp $
+# $Id: structuretags.pm,v 1.190 2003/06/25 16:47:47 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -149,11 +149,8 @@
 	}
 	if ($ENV{'form.resetdata'} eq 'New Problem Variation' ||
 	    $ENV{'form.newrandomization'} eq 'New Randomization') {
-	    $rndseed=time;
-	    if ($rndseed eq $ENV{'form.rndseed'}) {
-		srand($rndseed);
-		$rndseed=int(rand(1000000000));
-	    }
+	    srand(time);
+	    $rndseed=int(rand(2100000000));
 	    $ENV{'form.rndseed'}=$rndseed;
 	    delete($ENV{'form.resetdata'});
 	    delete($ENV{'form.newrandomization'});