diff --git a/VERSION b/VERSION index 68ca3e72..bbdee3ed 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 2.0.9 (2012-09-29 17:56:36) dev +Version 2.0.9 (2012-09-29 18:35:01) dev diff --git a/gluon/utils.py b/gluon/utils.py index 687eeead..94376894 100644 --- a/gluon/utils.py +++ b/gluon/utils.py @@ -157,8 +157,8 @@ def web2py_uuid(ctokens=UNPACKED_CTOKENS): It works like uuid.uuid4 except that tries to use os.urandom() if possible and it XORs the output with the tokens uniquely associated with this machine. """ - rand_longs = struct.unpack('=QQ', bytes(bytearray( - random.randrange(256) for i in xrange(16)))) + rand_longs = struct.unpack('=QQ', string.join( + (chr(random.randrange(256)) for i in xrange(16)),'')) if HAVE_URANDOM: urand_longs = struct.unpack('=QQ', fast_urandom16()) byte_s = struct.pack('=QQ',