[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

commit-queue at webkit.org commit-queue at webkit.org
Wed Dec 22 15:02:33 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 181428011e59f214e35edb5e3b071a6941fb7c44
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Wed Oct 27 17:51:26 2010 +0000

    2010-10-27  Gabor Rapcsanyi  <rgabor at inf.u-szeged.hu>
    
            Reviewed by Tony Chang.
    
            [NRWT] Fix http lock on Windows platform
            https://bugs.webkit.org/show_bug.cgi?id=48321
    
            * Scripts/webkitpy/layout_tests/port/http_lock.py:
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70672 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index c1e813e..aecf674 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,3 +1,12 @@
+2010-10-27  Gabor Rapcsanyi  <rgabor at inf.u-szeged.hu>
+
+        Reviewed by Tony Chang.
+
+        [NRWT] Fix http lock on Windows platform
+        https://bugs.webkit.org/show_bug.cgi?id=48321
+
+        * Scripts/webkitpy/layout_tests/port/http_lock.py:
+
 2010-10-27  Satish Sampath  <satish at chromium.org>
 
         Unreviewed, rolling out r70665.
diff --git a/WebKitTools/Scripts/webkitpy/layout_tests/port/http_lock.py b/WebKitTools/Scripts/webkitpy/layout_tests/port/http_lock.py
index 73200a0..b2615a3 100644
--- a/WebKitTools/Scripts/webkitpy/layout_tests/port/http_lock.py
+++ b/WebKitTools/Scripts/webkitpy/layout_tests/port/http_lock.py
@@ -71,13 +71,15 @@ class HttpLock(object):
         return self._extract_lock_number(lock_list[-1]) + 1
 
     def _check_pid(self, current_pid):
-        """Return True if pid is alive, otherwise return False."""
-        try:
-            os.kill(current_pid, 0)
-        except OSError:
-            return False
-        else:
-            return True
+        """Return True if pid is alive, otherwise return False.
+        FIXME: os.kill() doesn't work on Windows for checking if
+        a pid is alive, so always return True"""
+        if sys.platform in ('darwin', 'linux2'):
+            try:
+                os.kill(current_pid, 0)
+            except OSError:
+                return False
+        return True
 
     def _curent_lock_pid(self):
         """Return with the current lock pid. If the lock is not valid
@@ -89,9 +91,7 @@ class HttpLock(object):
             current_lock_file = open(lock_list[0], 'r')
             current_pid = current_lock_file.readline()
             current_lock_file.close()
-            if not (current_pid and
-              sys.platform in ('darwin', 'linux2') and
-              self._check_pid(int(current_pid))):
+            if not (current_pid and self._check_pid(int(current_pid))):
                 os.unlink(lock_list[0])
                 return
         except IOError, OSError:
@@ -104,9 +104,7 @@ class HttpLock(object):
         numbers are sequential."""
         while(True):
             try:
-                sequential_guard_lock = os.open(self._guard_lock_file,
-                                                os.O_CREAT | os.O_NONBLOCK | os.O_EXCL)
-
+                sequential_guard_lock = os.open(self._guard_lock_file, os.O_CREAT | os.O_EXCL)
                 self._process_lock_file_name = (self._lock_file_path_prefix +
                                                 str(self._next_lock_number()))
                 lock_file = open(self._process_lock_file_name, 'w')

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list