[issue4489] shutil.rmtree is vulnerable to a symlink attack

2011-09-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: Updated patch based on Eric's comments: Store _supports_safe_rmdir at the module level. Move imports up to module level Skip test on non-threading build -- Added file: http://bugs.python.org/file23261/i4489_v4.

[issue12797] io.FileIO and io.open should support openat

2011-09-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: Attached is a patch which adds dirfd= as a keyword argument. -- keywords: +patch Added file: http://bugs.python.org/file23272/i12797.patch ___ Python tracker <http://bugs.python.org/issue12

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2011-10-07 Thread Ross Lagerwall
Ross Lagerwall added the comment: http://bugs.python.org/review/4489/diff/3383/10563#newcode319 Lib/test/test_shutil.py:319: @unittest.skipIf(threading == None, 'requires threading') On 2011/10/07 19:29:47, eric.araujo wrote: > You can just say skipUnless(threading, 'm

[issue13150] Most of Python's startup time is sysconfig

2011-10-11 Thread Ross Lagerwall
Ross Lagerwall added the comment: #11454 is another case where pre-parsing and pickling the regular expressions in the email module may improve import time considerably. -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13

[issue11715] Building Python on multiarch Debian and Ubuntu

2011-10-14 Thread Ross Lagerwall
Ross Lagerwall added the comment: I see this requires dpkg-architecture which isn't always available. While it isn't hard to install it, it isn't very clear that this is the cause of the nis and crypt modules failing to build on a fresh install of 11.10. What would be nice i

[issue13195] subprocess: args with shell=True is not documented on Windows

2011-10-17 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13195> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13196] subprocess: undocumented if shell=True is necessary to find executable in Windows PATH

2011-10-17 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13196> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13197] subprocess: move shell arguments to a separate keyword param

2011-10-17 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13197> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12797] io.FileIO and io.open should support openat

2011-10-18 Thread Ross Lagerwall
Ross Lagerwall added the comment: I guess that would make it more general... I'll play around with it for a bit. It mustn't become too hard to use though since the original point was to simplify the opening of files :-) -- ___ Pyth

[issue13263] Group some os functions in submodules

2011-10-25 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13263> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13263] Group some os functions in submodules

2011-10-25 Thread Ross Lagerwall
Ross Lagerwall added the comment: Some functions would be easy to split off into separate modules conceptually like the sched_* functions and the cap_* functions (see #1615158). However, certain groups of functions like the *at functions cover a lot of different functionality and don&#

[issue12797] io.FileIO and io.open should support openat

2011-10-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: What would you envisage the API for the custom opener to look like? -- ___ Python tracker <http://bugs.python.org/issue12

[issue12797] io.FileIO and io.open should support openat

2011-10-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: Before I implement it properly, is this the kind of api that's desired? """ import os import io class MyOpener: def __init__(self, dirname): self.dirfd = os.open(dirname, os.O_RDONLY) def open(self, path, flags, m

[issue12797] io.FileIO and io.open should support openat

2011-10-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: The attached patch adds the opener keyword + tests. -- Added file: http://bugs.python.org/file23550/opener.patch ___ Python tracker <http://bugs.python.org/issue12

[issue12797] io.FileIO and io.open should support openat

2011-10-30 Thread Ross Lagerwall
Ross Lagerwall added the comment: Updated patch: * checks for long overflow * raises original exception if opener returns null * makes it explicit that "opener" must return an open file descriptor. I don't think that mode should be passed in since it is not specified in the par

[issue12797] io.FileIO and io.open should support openat

2011-10-31 Thread Ross Lagerwall
Ross Lagerwall added the comment: Thanks (and for the English lesson ;-) ) -- assignee: -> rosslagerwall resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.python

[issue13309] test_time fails: time data 'LMT' does not match format '%Z'

2011-11-01 Thread Ross Lagerwall
Ross Lagerwall added the comment: """ import time import sys t = time.gmtime(time.time()) s = time.strftime('%Z', t) print(s) time.mktime((-1, 1, 1, 0, 0, 0, -1, -1, -1)) t = time.gmtime(time.time()) s = time.strftime('%Z', t) print(s) ""&qu

[issue13309] test_time fails: time data 'LMT' does not match format '%Z'

2011-11-01 Thread Ross Lagerwall
Ross Lagerwall added the comment: It outputs: SAST LMT LMT An equivalent C program to the first test: """ #include #include #include int main() { time_t t; struct tm *tmp; t = time(NULL); tmp = localtime(&t); char str[200]; strftime(str, siz

[issue13339] Missing semicolon at Modules/posixsubprocess.c:4511

2011-11-03 Thread Ross Lagerwall
Ross Lagerwall added the comment: Thanks! -- assignee: -> rosslagerwall nosy: +rosslagerwall resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.python

[issue6397] Implementing Solaris "/dev/poll" in the "select" module

2011-11-07 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue6397> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2011-11-07 Thread Ross Lagerwall
Ross Lagerwall added the comment: Thanks Charles, I'll take your comments into account and take a look at making a general walker method. -- ___ Python tracker <http://bugs.python.org/i

[issue6397] Implementing Solaris "/dev/poll" in the "select" module

2011-11-09 Thread Ross Lagerwall
Ross Lagerwall added the comment: + increases this value, c:func:`devpoll` will return a possible + incomplete list of active file descriptors. I think this should change to: + increases this value, c:func:`devpoll` will return a possibly + incomplete list of active file descriptors

[issue6397] Implementing Solaris "/dev/poll" in the "select" module

2011-11-09 Thread Ross Lagerwall
Ross Lagerwall added the comment: Is write()ing a devpoll fd a blocking operation in the kernel? Does it need to have Py_BEGIN_ALLOW_THREADS around it? The same question applies for open()ing it. Obviously, the ioctl() call *is* blocking

[issue6397] Implementing Solaris "/dev/poll" in the "select" module

2011-11-09 Thread Ross Lagerwall
Ross Lagerwall added the comment: Also, you can use Py_RETURN_NONE instead of: +Py_INCREF(Py_None); +return Py_None; -- ___ Python tracker <http://bugs.python.org/issue6

[issue6397] Implementing Solaris "/dev/poll" in the "select" module

2011-11-09 Thread Ross Lagerwall
Ross Lagerwall added the comment: That was thorough :-) Seems OK though. +if (n < size) { +PyErr_SetString(PyExc_IOError, "failed to write all pollfds. " +"Please, report in http://bugs.python.org/";); If n < size, it's not a Pytho

[issue13309] test_time fails: time data 'LMT' does not match format '%Z'

2011-11-10 Thread Ross Lagerwall
Ross Lagerwall added the comment: Has it been reported? -- ___ Python tracker <http://bugs.python.org/issue13309> ___ ___ Python-bugs-list mailing list Unsub

[issue13424] Add examples for open’s new opener argument

2011-11-18 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13424> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13517] readdir() in os.listdir not threadsafe on OSX 10.6.8

2011-12-01 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13517> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13559] Use sendfile where possible in httplib

2011-12-10 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13559> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13564] ftplib and sendfile()

2011-12-10 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13564> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13530] Docs for os.lseek neglect to mention what it returns

2011-12-10 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13530> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13578] Add subprocess.iter_output() convenience function

2011-12-10 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13578> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9922] subprocess.getstatusoutput can fail with utf8 UnicodeDecodeError

2011-12-21 Thread Ross Lagerwall
Ross Lagerwall added the comment: getstatusoutput() is broken given that it doesn't work on windows yet it should. I'd also recommend leaving the behavior as is and deprecating the function (and getoutput() while we're at it). A related bug (#10197) also recomme

[issue11006] warnings with subprocess and pipe2

2011-12-21 Thread Ross Lagerwall
Ross Lagerwall added the comment: Removed the warnings. Thanks. -- assignee: -> rosslagerwall nosy: +rosslagerwall resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: +Python 3.3 ___ Python tr

[issue13684] httplib tunnel infinite loop

2012-01-02 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13684> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13694] asynchronous connect in asyncore.dispatcher does not set addr

2012-01-02 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue13694> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13609] Add "os.get_terminal_size()" function

2012-01-02 Thread Ross Lagerwall
Ross Lagerwall added the comment: Nice patch :-) I think the two function approach works well. Since you have already checked that termsize is not NULL, Py_DECREF can be used instead of Py_CLEAR. Would it not be better to use sys.__stdout__ instead of 1 in the documentation and to use

[issue13609] Add "os.get_terminal_size()" function

2012-01-02 Thread Ross Lagerwall
Ross Lagerwall added the comment: I'll try & investigate Solaris a bit... Also, what should be the default terminal size? Gnome-terminal and xterm seem to default to 80x24, not 80x25. -- ___ Python tracker <http://bugs.python.or

[issue12364] Deadlock in test_concurrent_futures

2012-01-02 Thread Ross Lagerwall
Ross Lagerwall added the comment: Retrieving the result of a future after the executor has been shut down can cause a hang. It seems like this regression was introduced in a76257a99636. This regression exists only for ProcessPoolExecutor. The problem is that even if there are pending work

[issue12364] Deadlock in test_concurrent_futures

2012-01-02 Thread Ross Lagerwall
Changes by Ross Lagerwall : Added file: http://bugs.python.org/file24129/itest.py ___ Python tracker <http://bugs.python.org/issue12364> ___ ___ Python-bugs-list mailin

[issue13713] Regression for http.client read()

2012-01-04 Thread Ross Lagerwall
New submission from Ross Lagerwall : 806cfe39f729 introduced a regression for http.client read(len). To see this: $ ./python test.py $ wget http://archives.fedoraproject.org/pub/archive/fedora/linux/core/1/SRPMS/ $ diff index.html index2.html This is a difference in the files (which there

[issue13713] Regression for http.client read()

2012-01-04 Thread Ross Lagerwall
Ross Lagerwall added the comment: The patch looks right and seems to fix the issue. Thanks :-) -- ___ Python tracker <http://bugs.python.org/issue13713> ___ ___

[issue13734] Add a generic directory walker method to avoid symlink attacks

2012-01-07 Thread Ross Lagerwall
Ross Lagerwall added the comment: > Has there already been done any work? Ross mentioned he wanted to take a stab? Unfortunately, I'm rather busy at the moment but when I get some free time and if no one else wants to work on it then I'l

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-01-07 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- dependencies: +Add a generic directory walker method to avoid symlink attacks ___ Python tracker <http://bugs.python.org/issue4

[issue12364] Deadlock in test_concurrent_futures

2012-01-08 Thread Ross Lagerwall
Ross Lagerwall added the comment: Thanks! -- assignee: -> rosslagerwall resolution: -> fixed stage: -> committed/rejected status: open -> closed type: -> behavior ___ Python tracker <http://bugs.pyt

[issue13739] os.fdlistdir() is not idempotent

2012-01-08 Thread Ross Lagerwall
Ross Lagerwall added the comment: > I see two options: > 1. rewind the directory stream in fdlistdir() > 2. document this > > Here's a patch for option 1. Yeah, looks good. -- ___ Python tracker <http://bug

[issue13734] Add a generic directory walker method to avoid symlink attacks

2012-01-08 Thread Ross Lagerwall
Ross Lagerwall added the comment: > I'm currently leaning towards the simple 4-tuple approach I would also take that approach. It seems simplest to me. -- ___ Python tracker <http://bugs.python.org

[issue13757] os.fdlistdir() should not close the file descriptor given in argument

2012-01-10 Thread Ross Lagerwall
Ross Lagerwall added the comment: The reason I made it like that was that it seemed "closer" to the fdopendir() function which steals the fd for internal use. However, I agree that it makes more sense to dup() it. Patch looks good. --

[issue13777] socket: communicating with Mac OS X KEXT controls

2012-01-12 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +ned.deily, ronaldoussoren ___ Python tracker <http://bugs.python.org/issue13777> ___ ___ Python-bugs-list mailing list Unsub

[issue12158] platform: add linux_version()

2011-05-23 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue12158> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12183] Document behaviour of shutil.copy2 and copystat with symlinks

2011-05-25 Thread Ross Lagerwall
Ross Lagerwall added the comment: Python 3.3 (as yet unreleased) supports the lutimes function: http://docs.python.org/dev/py3k/library/os.html#os.lutimes Python 2.7 is not getting any more features so it will not be added. I'm changing the title to the second part of your que

[issue12196] add pipe2() to the os module

2011-05-28 Thread Ross Lagerwall
Ross Lagerwall added the comment: Out of interest, is there any reason that the configure check for pipe2 is a special case near the bottom of configure.in instead of with all the other function checks in the AC_CHECK_FUNCS[] section in the middle? I know this patch didn't write the conf

[issue12196] add pipe2() to the os module

2011-05-28 Thread Ross Lagerwall
Ross Lagerwall added the comment: >> Also, the pure python implementation of subprocess for posix can now >> be >> updated to use pipe2 if it exists (previously on _posixsubprocess.c >> used it). > I don't understand the last part :-) > What do you suggest

[issue12230] test_subprocess.test_pass_fds() failed on x86 Tiger 3.x

2011-05-31 Thread Ross Lagerwall
Ross Lagerwall added the comment: Could this be related to http://bugs.python.org/issue6559#msg123958? Or Issue10826? -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue12

[issue12230] test_subprocess.test_pass_fds() failed on x86 Tiger 3.x

2011-06-01 Thread Ross Lagerwall
Ross Lagerwall added the comment: > These failures were specific to Solaris/OpenIndiana: they were "door files" Yeah, I saw that but thought maybe the reason was similar, some library function in the child process was opening a file and not closing it properly. > using -m

[issue11504] test_subprocess failure

2011-06-03 Thread Ross Lagerwall
Ross Lagerwall added the comment: All stable buildbots appear to be green, so closing... -- nosy: +rosslagerwall resolution: -> fixed status: open -> closed ___ Python tracker <http://bugs.python.org/i

[issue11941] Support st_atim, st_mtim and st_ctim attributes in os.stat_result

2011-06-03 Thread Ross Lagerwall
Ross Lagerwall added the comment: Attached is a patch for review. It adds st_atim, st_ctim and st_mtim. They are defined even when the underlying system does not have nanosecond precision. -- keywords: +patch stage: -> patch review Added file: http://bugs.python.org/file22

[issue11941] Support st_atim, st_mtim and st_ctim attributes in os.stat_result

2011-06-07 Thread Ross Lagerwall
Ross Lagerwall added the comment: Here is an updated patch that uses the atim, ctim and mtim variables (which are assigned based on various #ifdefs). This should now work on Linux, BSD and Windows. -- Added file: http://bugs.python.org/file22279/issue11941_2.patch

[issue9344] please add posix.getgrouplist()

2011-06-09 Thread Ross Lagerwall
Ross Lagerwall added the comment: Thanks! -- resolution: -> accepted stage: commit review -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.python.o

[issue9344] please add posix.getgrouplist()

2011-06-10 Thread Ross Lagerwall
Ross Lagerwall added the comment: > Nit: when a patch gets committed and the issue closed, the preferred > resolution is "fixed" ;) > (see http://docs.python.org/devguide/triaging.html#resolution) Sure, I will try remember that. -- ___

[issue12326] Linux 3: tests should avoid using sys.platform == 'linux2'

2011-06-13 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue12326> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12326] Linux 3: tests should avoid using sys.platform == 'linux2'

2011-06-20 Thread Ross Lagerwall
Ross Lagerwall added the comment: > That's exactly my point. > Code checking sys.platform against 'linux2' is already broken, there's > no point in complicating the code further, or adding a new constant. > If you want to check for a specific operating system, t

[issue10635] Calling subprocess.Popen with preexec_fn=signal.pause blocks forever

2011-06-23 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- status: pending -> closed ___ Python tracker <http://bugs.python.org/issue10635> ___ ___ Python-bugs-list mailing list Unsubscri

[issue10636] subprocess module has race condition with SIGCHLD handlers

2011-06-23 Thread Ross Lagerwall
Ross Lagerwall added the comment: > The right approach is to use sigblock/sigsetmask before creating the > process, and then again after creating it. Unfortunately, these aren't > exposed from the signal module. Since 3.3, pthread_sigmask is exposed so the right approach ca

[issue12303] expose sigwaitinfo() and sigtimedwait() in the signal module

2011-06-24 Thread Ross Lagerwall
Ross Lagerwall added the comment: Here's a patch to add the two functions (with docs and tests). You'll need to run autoreconf before compiling. -- assignee: -> rosslagerwall keywords: +patch nosy: +rosslagerwall stage: -> patch review type: -> feature reque

[issue12303] expose sigwaitinfo() and sigtimedwait() in the signal module

2011-06-24 Thread Ross Lagerwall
Ross Lagerwall added the comment: Thanks for the review. > Why do you wait until the end of PyInit_signal() to set initialized to 1? Fixed. > If this variable is only present ... but I see that the init function of the > posixmodule.c has also a static initialized variable. I simply

[issue12303] expose sigwaitinfo() and sigtimedwait() in the signal module

2011-06-24 Thread Ross Lagerwall
Ross Lagerwall added the comment: > What do you mean? signal.SIGPOLL exists in Python 3.3. Right, si_band added. > - test_sigwaitinfo(), test_sigtimedwait_poll(), > test_sigwaitinfo_interrupted() are called from a child process. In > test_wait(), I chose to write manually to std

[issue12404] c99 code in mmapmodule

2011-06-25 Thread Ross Lagerwall
Ross Lagerwall added the comment: Thanks! -- assignee: -> rosslagerwall nosy: +rosslagerwall resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: +Python 3.3 ___ Python tracker <http://bugs.python

[issue12303] expose sigwaitinfo() and sigtimedwait() in the signal module

2011-06-26 Thread Ross Lagerwall
Ross Lagerwall added the comment: >From the FreeBSD 6.4 buildbot: """ [172/356/2] test_signal error: 'NoneType' object has no attribute 'si_signo' error: False is not true test test_signal failed -- multiple errors occurred; run in verbose mode for

[issue12303] expose sigwaitinfo() and sigtimedwait() in the signal module

2011-06-30 Thread Ross Lagerwall
Ross Lagerwall added the comment: The tests seem to be working fine on all the buildbots now... Thanks! -- resolution: -> accepted stage: commit review -> committed/rejected status: open -> closed ___ Python tracker <http://bug

[issue12456] Hangs in concurrent.futures

2011-06-30 Thread Ross Lagerwall
New submission from Ross Lagerwall : 6d6099f7fe89 introduced a regression. It causes the following code to hang fairly reliably for me: """ import concurrent.futures import math def is_prime(n): print(sqt(81)) < Note the type error! de

[issue12456] Hangs in concurrent.futures

2011-06-30 Thread Ross Lagerwall
Ross Lagerwall added the comment: Further analysis seems to indicate that it is a race between the shutdown code and the processes finishing. This code hangs: """ executor = concurrent.futures.ProcessPoolExecutor(2) executor.map(is_prime, [1, 2]) executor.shutdown() "&q

[issue12456] Hangs in concurrent.futures

2011-07-01 Thread Ross Lagerwall
Ross Lagerwall added the comment: Yes, the patch does appear to fix the issue. Thanks -- ___ Python tracker <http://bugs.python.org/issue12456> ___ ___ Pytho

[issue12502] 100% cpu usage when using asyncore with UNIX socket

2011-07-05 Thread Ross Lagerwall
Ross Lagerwall added the comment: Looks good, the patch seems to fix the problem. This section of code indicates that the accepting socket shouldn't be in the write set... def handle_write_event(self): if self.accepting: # Accepting sockets shouldn't get a w

[issue12522] Implement `os.startfile` under Linux and Mac

2011-07-09 Thread Ross Lagerwall
Ross Lagerwall added the comment: I think this is a duplicate of #3177. -- nosy: +rosslagerwall resolution: -> duplicate status: open -> closed ___ Python tracker <http://bugs.python.org/i

[issue3177] implement os.startfile on posix and MacOSX

2011-07-09 Thread Ross Lagerwall
Ross Lagerwall added the comment: Closed #12522 as a duplicate. It contains a link to a discussion on python-ideas requesting the feature. -- nosy: +rosslagerwall versions: +Python 3.3 -Python 3.2 ___ Python tracker <http://bugs.python.

[issue12494] subprocess: check_output() doesn't close pipes on error

2011-07-11 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue12494> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12517] Large file support on Windows: sizeof(off_t) is 32 bits

2011-07-11 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue12517> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12556] Disable size checks in mmap.mmap()

2011-07-21 Thread Ross Lagerwall
Ross Lagerwall added the comment: > I don't like the idea of adding an argument which doesn't have a > counterpart in the POSIX version (especially to address such corner > cases). Indeed, it seems rather messy for a corner case that may well not exist. If there are defini

[issue12556] Disable size checks in mmap.mmap()

2011-07-21 Thread Ross Lagerwall
Ross Lagerwall added the comment: > That's what I thought, it's really uncommon: in that case, I'm > reluctant to making such a change, for the reason explained above. > Ross, Victor? Even if Linux did accept a a length of 0 (which it doesn't since 2.6.12), what

[issue12607] subprocess(stdout=..., stderr=sys.stdout) breaks stderr for child

2011-07-22 Thread Ross Lagerwall
Ross Lagerwall added the comment: It is indeed a problem. It seems like the problem comes about due to the "swapping" of fds. i.e. using stdout as stderr. The reverse appears to work due to the order in which the dup() calls are performed. Attached is a patch which fixes

[issue12102] mmap requires file to be synced

2011-07-24 Thread Ross Lagerwall
Ross Lagerwall added the comment: Thanks! -- assignee: -> rosslagerwall resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: +Python 3.3 ___ Python tracker <http://bugs.python

[issue12607] subprocess(stdout=..., stderr=sys.stdout) breaks stderr for child

2011-07-24 Thread Ross Lagerwall
Ross Lagerwall added the comment: Attached is a patch which tests all combinations and includes a testcase. -- nosy: +pitrou Added file: http://bugs.python.org/file22747/i12607_v2.patch ___ Python tracker <http://bugs.python.org/issue12

[issue12607] subprocess(stdout=..., stderr=sys.stdout) breaks stderr for child

2011-07-25 Thread Ross Lagerwall
Ross Lagerwall added the comment: communicate() requires setting stdin, stdout and stderr to subprocess.PIPE which defeats the purpose of the test: setting them to 0, 1 and 2 (in various orders) so that they need to be swapped... -- ___ Python

[issue12607] subprocess(stdout=..., stderr=sys.stdout) breaks stderr for child

2011-07-27 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- assignee: -> rosslagerwall resolution: -> fixed stage: -> committed/rejected status: open -> closed type: -> behavior ___ Python tracker <http://bugs.pyt

[issue12650] Subprocess leaks fd upon kill()

2011-07-28 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue12650> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12650] Subprocess leaks fd upon kill()

2011-07-28 Thread Ross Lagerwall
Ross Lagerwall added the comment: The patches look good and seem to fix the issue. -- ___ Python tracker <http://bugs.python.org/issue12650> ___ ___ Python-bug

[issue12682] Meaning of 'accepted' resolution as documented in devguide

2011-08-02 Thread Ross Lagerwall
Ross Lagerwall added the comment: > Formally I believe that the 'accepted' resolution is for committed feature > requests That's what I also thought originally. Perhaps this should be discussed on Python-Dev to see what people think it should mean? --

[issue12702] shutil.copytree() should use os.lutimes() to copy the metadata of symlinks

2011-08-08 Thread Ross Lagerwall
Changes by Ross Lagerwall : -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue12702> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12801] C realpath not used by os.path.realpath

2011-08-20 Thread Ross Lagerwall
Ross Lagerwall added the comment: An initial patch. The first problem is that before, os.path.realpath('') == os.path.realpath('.') but this is not true for realpath(3). Thus, the test suite does not run because it relies on this behaviour. -- keywords: +pa

[issue12786] subprocess wait() hangs when stdin is closed

2011-08-25 Thread Ross Lagerwall
Ross Lagerwall added the comment: Patch looks good after Victor's comment. -- ___ Python tracker <http://bugs.python.org/issue12786> ___ ___ Python-bugs-l

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: Does it always segfault? Try: ./python -c 'import os; print(os.fdlistdir(os.open("/tmp", os.O_RDONLY)))' with various values for /tmp. >From what I can see, the code for fdlistdir is basically the same as >os.listdir(). If possible

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: > It looks like a kernel bug !? That's what I thought given that it appears to be working on all the other platforms. -- ___ Python tracker <http://bugs.python.org

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: I'm not sure what the status of Python and OpenBSD support is but I just tried the latest stable version of OpenBSD (4.9) in VirtualBox and it won't compile fully. It segfaults while trying to run setup.py (I think). I see you're running OpenB

[issue12801] C realpath not used by os.path.realpath

2011-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: > I've been quite disappointed by POSIX lately... POSIX the standard, or the implementers?? -- ___ Python tracker <http://bugs.python.org

[issue12494] subprocess: check_output() doesn't close pipes on error

2011-08-31 Thread Ross Lagerwall
Ross Lagerwall added the comment: The second patch looks good. Tests? I think it would be better to kill the process than to let it carry on. But, it *probably* shouldn't be applied to 2.7 & 3.2 given that it is a behaviour change. -- _

[issue12494] subprocess: check_output() doesn't close pipes on error

2011-09-01 Thread Ross Lagerwall
Ross Lagerwall added the comment: > I consider that this issue is a bug, so it should be fixed in 2.7 and > 3.2. I agree that *killing* the process is a behaviour change, but we > can just close pipes on error for 2.7 and 3.2. Yeah, that se

[issue12898] add opendir() for POSIX platforms

2011-09-05 Thread Ross Lagerwall
Ross Lagerwall added the comment: Also see fdopendir(3) which allows you to pass an open file descriptor to get a C dirent struct. This is implemented in the os module too but instead of returning a struct, it returns a list. -- ___ Python

[issue12898] add opendir() for POSIX platforms

2011-09-05 Thread Ross Lagerwall
Ross Lagerwall added the comment: opendir opens a C dirent structure with an underlying file descriptor. However, to open a directory file descriptor, simple use: os.open("/tmp", os.O_RDONLY) This can then be used as the fd to the functions which require a directory fd like

[issue12899] Change os.utimensat() and os.futimens() to use float for atime & mtime

2011-09-05 Thread Ross Lagerwall
Ross Lagerwall added the comment: See #11457 for a long discussion about the API and whether to use decimal or not to get the full precision. -- nosy: +rosslagerwall ___ Python tracker <http://bugs.python.org/issue12

  1   2   3   4   >