You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by pq...@apache.org on 2009/12/18 02:57:18 UTC

svn commit: r892106 - /incubator/libcloud/trunk/libcloud/drivers/rackspace.py

Author: pquerna
Date: Fri Dec 18 01:57:18 2009
New Revision: 892106

URL: http://svn.apache.org/viewvc?rev=892106&view=rev
Log:
Simplify the random hex appending to rackspace requests, don't need crc32 or anything crazy here.

Modified:
    incubator/libcloud/trunk/libcloud/drivers/rackspace.py

Modified: incubator/libcloud/trunk/libcloud/drivers/rackspace.py
URL: http://svn.apache.org/viewvc/incubator/libcloud/trunk/libcloud/drivers/rackspace.py?rev=892106&r1=892105&r2=892106&view=diff
==============================================================================
--- incubator/libcloud/trunk/libcloud/drivers/rackspace.py (original)
+++ incubator/libcloud/trunk/libcloud/drivers/rackspace.py Fri Dec 18 01:57:18 2009
@@ -19,7 +19,6 @@
 from zope.interface import implements
 
 import os
-from zlib import crc32
 
 import time
 import base64
@@ -111,7 +110,7 @@
         if method == "POST":
             headers = {'Content-Type': 'application/xml; charset=UTF-8'}
         if method == "GET":
-          params['cache-busting'] = hex(crc32(os.urandom(16)))
+          params['cache-busting'] = os.urandom(8).encode('hex')
         return super(RackspaceConnection, self).request(action=action,
                                                         params=params, data=data,
                                                         method=method, headers=headers)