diff options
author | Jacek Antonelli | 2008-08-15 23:45:16 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-08-15 23:45:16 -0500 |
commit | 3f27ba891ac4d032753b219b4b96d1ffbc9fb488 (patch) | |
tree | 504932ee91a0356fba7ea48798887c96867e492f /linden/indra/lib/python | |
parent | Second Life viewer sources 1.18.4.3 (diff) | |
download | meta-impy-3f27ba891ac4d032753b219b4b96d1ffbc9fb488.zip meta-impy-3f27ba891ac4d032753b219b4b96d1ffbc9fb488.tar.gz meta-impy-3f27ba891ac4d032753b219b4b96d1ffbc9fb488.tar.bz2 meta-impy-3f27ba891ac4d032753b219b4b96d1ffbc9fb488.tar.xz |
Second Life viewer sources 1.18.5.0-RC
Diffstat (limited to 'linden/indra/lib/python')
-rw-r--r-- | linden/indra/lib/python/indra/base/lluuid.py | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/linden/indra/lib/python/indra/base/lluuid.py b/linden/indra/lib/python/indra/base/lluuid.py index f302f8b..5209de4 100644 --- a/linden/indra/lib/python/indra/base/lluuid.py +++ b/linden/indra/lib/python/indra/base/lluuid.py | |||
@@ -27,6 +27,7 @@ $/LicenseInfo$ | |||
27 | """ | 27 | """ |
28 | 28 | ||
29 | import md5, random, socket, string, time, re | 29 | import md5, random, socket, string, time, re |
30 | import uuid | ||
30 | 31 | ||
31 | def _int2binstr(i,l): | 32 | def _int2binstr(i,l): |
32 | s='' | 33 | s='' |
@@ -187,14 +188,8 @@ class UUID(object): | |||
187 | from c++ implementation for portability reasons. | 188 | from c++ implementation for portability reasons. |
188 | Returns self. | 189 | Returns self. |
189 | """ | 190 | """ |
190 | newid = self.__class__.lastid | ||
191 | while newid == self.__class__.lastid: | ||
192 | now = long(time.time() * 1000) | ||
193 | newid = ("%016x" % now) + self.__class__.hexip | ||
194 | newid += ("%03x" % (self.__class__.rand.randrange(0,4095))) | ||
195 | self.__class__.lastid = newid | ||
196 | m = md5.new() | 191 | m = md5.new() |
197 | m.update(newid) | 192 | m.update(uuid.uuid1().bytes) |
198 | self._bits = m.digest() | 193 | self._bits = m.digest() |
199 | return self | 194 | return self |
200 | 195 | ||