forked from pool/python-lockfile
- added a patch to fix a TypeError in LockBase.__init__ when the current
thread has ident == None OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-lockfile?expand=0&rev=8
This commit is contained in:
committed by
Git OBS Bridge
parent
00c8b973b5
commit
ef1421c703
11
python-lockfile-empty_ident.patch
Normal file
11
python-lockfile-empty_ident.patch
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
--- lockfile-0.9.1/lockfile/__init__.py.orig 2012-02-02 13:32:51.133789612 +0100
|
||||||
|
+++ lockfile-0.9.1/lockfile/__init__.py 2012-02-02 13:33:13.024241010 +0100
|
||||||
|
@@ -167,7 +167,7 @@
|
||||||
|
t = threading.current_thread()
|
||||||
|
# Thread objects in Python 2.4 and earlier do not have ident
|
||||||
|
# attrs. Worm around that.
|
||||||
|
- ident = getattr(t, "ident", hash(t))
|
||||||
|
+ ident = getattr(t, "ident", hash(t)) or hash(t)
|
||||||
|
self.tname = "-%x" % (ident & 0xffffffff)
|
||||||
|
else:
|
||||||
|
self.tname = ""
|
||||||
@@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Feb 2 13:41:07 CET 2012 - iartarisi@suse.cz
|
||||||
|
|
||||||
|
- added a patch to fix a TypeError in LockBase.__init__ when the current
|
||||||
|
thread has ident == None
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Sat Apr 16 00:09:30 UTC 2011 - alexandre@exatati.com.br
|
Sat Apr 16 00:09:30 UTC 2011 - alexandre@exatati.com.br
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-lockfile
|
# spec file for package python-lockfile
|
||||||
#
|
#
|
||||||
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@@ -23,12 +23,13 @@
|
|||||||
|
|
||||||
Name: python-%{mod_name}
|
Name: python-%{mod_name}
|
||||||
Version: 0.9.1
|
Version: 0.9.1
|
||||||
Release: 1
|
Release: 0
|
||||||
Url: http://code.google.com/p/pylockfile/
|
Url: http://code.google.com/p/pylockfile/
|
||||||
Summary: Platform-independent file locking module
|
Summary: Platform-independent file locking module
|
||||||
License: MIT License
|
License: MIT
|
||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Source: %{mod_name}-%{version}.tar.bz2
|
Source: %{mod_name}-%{version}.tar.bz2
|
||||||
|
Patch0: %{name}-empty_ident.patch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
BuildRequires: python-devel
|
BuildRequires: python-devel
|
||||||
%if 0%{?suse_version}
|
%if 0%{?suse_version}
|
||||||
@@ -51,6 +52,10 @@ production-quality code.
|
|||||||
%prep
|
%prep
|
||||||
%setup -q -n %{mod_name}-%{version}
|
%setup -q -n %{mod_name}-%{version}
|
||||||
|
|
||||||
|
# current thread has ident = None, which causes a TypeError
|
||||||
|
# http://code.google.com/p/pylockfile/issues/detail?id=8
|
||||||
|
%patch0 -p1 -b .empty_ident
|
||||||
|
|
||||||
%build
|
%build
|
||||||
export CFLAGS="%{optflags}"
|
export CFLAGS="%{optflags}"
|
||||||
python setup.py build
|
python setup.py build
|
||||||
|
|||||||
Reference in New Issue
Block a user