Please review this at http://codereview.appspot.com/2574042/

Affected files:
  M trytond/wizard/wizard.py


Index: trytond/wizard/wizard.py
===================================================================
--- a/trytond/wizard/wizard.py
+++ b/trytond/wizard/wizard.py
@@ -3,7 +3,7 @@
 import copy
 from threading import Lock
 from random import randint
-from sys import maxint
+from xmlrpclib import MAXINT
 from trytond.pool import Pool
 from trytond.transaction import Transaction

@@ -108,7 +108,7 @@
         self._lock.acquire()
         wiz_id = 0
         while True:
-            wiz_id = randint(0, maxint)
+            wiz_id = randint(0, MAXINT)
             if wiz_id not in self._datas:
                 break
         self._datas[wiz_id] = {'user': Transaction().user, '_wiz_id':
wiz_id}



-- 
Cédric Krier

B2CK SPRL
Rue de Rotterdam, 4
4000 Liège
Belgium
Tel: +32 472 54 46 59
Email/Jabber: [email protected]
Website: http://www.b2ck.com/

Attachment: pgpSYJHVoHaqN.pgp
Description: PGP signature

Reply via email to