Package: deal / 3.1.9-12

seed-getpid Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
deal (3.0.8-4) unstable; urgency=low

  * Xor the seed with getpid() to make deals more random.

 -- Christoph Berg <myon@debian.org>  Wed, 30 Aug 2006 01:37:28 +0200

2009-06-13: Refreshed for 3.1.7; upstream's fix was incomplete.

--- a/tcl_deal.c
+++ b/tcl_deal.c
@@ -506,7 +506,7 @@ int old_main(argc,argv)
 #ifdef USE_RAND48
   srand48(for_seeding ^ getpid());
 #else
-  srandom(for_seeding);
+  srandom(for_seeding ^ getpid());
 #endif
 
   init_name_tables();