New way of generating .pyc files, thanks to Sjoerd.

urllib.py: '+' is not always safe (even though the RFC says so :-( )
whrandom.py: throw away top bits of time to avoid overflow on Mac
(where times can be negative)
This commit is contained in:
Guido van Rossum 1994-08-29 10:52:58 +00:00
parent 7b1e974b4b
commit 3bb5448767
5 changed files with 96 additions and 2 deletions

View file

@ -39,7 +39,7 @@ class whrandom:
if x is None:
# Initialize from current time
import time
t = int(time.time())
t = int(time.time() % 0x80000000)
t, x = divmod(t, 256)
t, y = divmod(t, 256)
t, z = divmod(t, 256)