Permalink
Browse files

merging hell

  • Loading branch information...
1 parent f7349a5 commit 503609b82dda66334da93c0a9831a7f53d524867 BuzzTroll committed Oct 6, 2010
Showing with 16 additions and 5 deletions.
  1. +16 −5 cumulus/cb/pycb/cumulus.py
View
@@ -283,16 +283,27 @@ def allHeadersReceived(self):
if ndx >= 0:
rPath = rPath[0:ndx]
rPath = createPath(h, rPath)
-# try:
-# user = authorize(h, self._command, rPath, self._path)
-# except:
-# self.send_access_error(req)
-# return
+ try:
+ user = authorize(h, self._command, rPath, self._path)
+ except:
+ self.send_access_error()
+ return
if 'expect' in h:
if h['expect'].lower() == '100-continue':
self.transport.write("HTTP/1.1 100 Continue\r\n\r\n")
+ global count_locks
+ global g_connection_count
+ count_lock.acquire()
+ try:
+ g_connection_count = g_connection_count + 1
+ d = req.notifyFinish()
+ d.addBoth(cb_expired)
+ finally:
+ count_lock.release()
+
+
(bucketName, objectName) = path_to_bucket_object(rPath)
# if we are putting an object
if objectName != None and self._command == "PUT":

0 comments on commit 503609b

Please sign in to comment.