diff options
Diffstat (limited to 'lang/python23-nth/patches/patch-bb')
-rw-r--r-- | lang/python23-nth/patches/patch-bb | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/lang/python23-nth/patches/patch-bb b/lang/python23-nth/patches/patch-bb new file mode 100644 index 00000000000..d13abcc3656 --- /dev/null +++ b/lang/python23-nth/patches/patch-bb @@ -0,0 +1,34 @@ +$NetBSD: patch-bb,v 1.1.1.1 2005/01/23 22:57:21 recht Exp $ + +--- Lib/posixfile.py.orig 2004-06-07 16:19:35.000000000 +0200 ++++ Lib/posixfile.py +@@ -182,11 +182,11 @@ class _posixfile_: + # Hack by davem@magnet.com to get locking to go on freebsd; + # additions for AIX by Vladimir.Marangozov@imag.fr + import sys, os +- if sys.platform in ('netbsd1', ++ if sys.platform in ('netbsd1', 'netbsd2', + 'openbsd2', + 'freebsd2', 'freebsd3', 'freebsd4', 'freebsd5', + 'bsdos2', 'bsdos3', 'bsdos4'): +- flock = struct.pack('lxxxxlxxxxlhh', \ ++ flock = struct.pack('qqihh', \ + l_start, l_len, os.getpid(), l_type, l_whence) + elif sys.platform in ['aix3', 'aix4']: + flock = struct.pack('hhlllii', \ +@@ -198,12 +198,12 @@ class _posixfile_: + flock = fcntl.fcntl(self._file_.fileno(), cmd, flock) + + if '?' in how: +- if sys.platform in ('netbsd1', ++ if sys.platform in ('netbsd1', 'netbsd2' + 'openbsd2', + 'freebsd2', 'freebsd3', 'freebsd4', 'freebsd5', + 'bsdos2', 'bsdos3', 'bsdos4'): + l_start, l_len, l_pid, l_type, l_whence = \ +- struct.unpack('lxxxxlxxxxlhh', flock) ++ struct.unpack('qqihh', flock) + elif sys.platform in ['aix3', 'aix4']: + l_type, l_whence, l_start, l_len, l_sysid, l_pid, l_vfs = \ + struct.unpack('hhlllii', flock) + |