diff options
author | Josh Bell <josh@lindenlab.com> | 2007-10-25 22:31:09 +0000 |
---|---|---|
committer | Josh Bell <josh@lindenlab.com> | 2007-10-25 22:31:09 +0000 |
commit | 833e8d5c2a1dd48fd89b8b438dbe56572697bb76 (patch) | |
tree | 20103c6dbd8b28f8a70599c1b94c419e5cfca970 /indra/lib | |
parent | ca6f7419824a06b42f7e4fac03ea6bedfe54cd62 (diff) |
svn merge -r 71403:72356 svn+ssh://svn.lindenlab.com/svn/linden/branches/Branch_1-18-3-Server --> release
Backport of fixes from production branch. Merge verified with QAR-41
Diffstat (limited to 'indra/lib')
-rw-r--r-- | indra/lib/python/indra/base/lluuid.py | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/indra/lib/python/indra/base/lluuid.py b/indra/lib/python/indra/base/lluuid.py index f302f8b002..5209de45a0 100644 --- a/indra/lib/python/indra/base/lluuid.py +++ b/indra/lib/python/indra/base/lluuid.py @@ -27,6 +27,7 @@ $/LicenseInfo$ """ import md5, random, socket, string, time, re +import uuid def _int2binstr(i,l): s='' @@ -187,14 +188,8 @@ class UUID(object): from c++ implementation for portability reasons. Returns self. """ - newid = self.__class__.lastid - while newid == self.__class__.lastid: - now = long(time.time() * 1000) - newid = ("%016x" % now) + self.__class__.hexip - newid += ("%03x" % (self.__class__.rand.randrange(0,4095))) - self.__class__.lastid = newid m = md5.new() - m.update(newid) + m.update(uuid.uuid1().bytes) self._bits = m.digest() return self |