Fix for portfolio.
authorMorgan Deters <mdeters@cs.nyu.edu>
Tue, 11 Mar 2014 22:47:28 +0000 (18:47 -0400)
committerMorgan Deters <mdeters@cs.nyu.edu>
Tue, 11 Mar 2014 22:47:42 +0000 (18:47 -0400)
src/main/portfolio_util.cpp

index a2d0ff700a85baec55ebf408fa9daa1f12741c43..e4fcf60248f552f8f0491b8302e351c1b80cc727 100644 (file)
@@ -34,7 +34,7 @@ vector<Options> parseThreadSpecificOptions(Options opts)
    * Use satRandomSeed for generating random numbers, in particular
    * satRandomSeed-s
    */
-  srand((unsigned int)(-opts[options::satRandomSeed]));
+  srand(-opts[options::satRandomSeed]);
 
   for(unsigned i = 0; i < numThreads; ++i) {
     threadOptions.push_back(opts);
@@ -45,7 +45,7 @@ vector<Options> parseThreadSpecificOptions(Options opts)
 
     // If the random-seed is negative, pick a random seed randomly
     if(opts[options::satRandomSeed] < 0) {
-      tOpts.set(options::satRandomSeed, (double)rand());
+      tOpts.set(options::satRandomSeed, unsigned(rand()));
     }
 
     if(i < opts[options::threadArgv].size() &&