New submission from Morten Bentsen <[EMAIL PROTECTED]>:

The uuid module uses a single global buffer for storing random values 
obtained from the system. This can (and does) cause non-uniqueness of 
generated id's when using the uuid4 function in a multithreaded program.

The following snippet shows the problem - _buffer is the global buffer:

    # When the system provides a version-4 UUID generator, use it.
    if _uuid_generate_random:
        _uuid_generate_random(_buffer)
        return UUID(bytes=_buffer.raw)

----------
components: Library (Lib)
messages: 77401
nosy: mortenab
severity: normal
status: open
title: uuid behavior with multiple threads
type: behavior
versions: Python 2.5

_______________________________________
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue4607>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to