Commit Graph

363 Commits

Author SHA1 Message Date
Neal Norwitz 05a45599d7 Patch #1309579: wait3 and wait4 were added to the posix module by Chad J. Schroeder.
This was a fair amount of rework of the patch.  Refactored test_fork1 so it
could be reused by the new tests for wait3/4.  Also made them into new style
unittests (derive from unittest.TestCase).
2006-03-20 06:30:08 +00:00
Neal Norwitz d1e0ef68fb SF #1445431, fix some leaks in error conditions. 2006-03-20 04:08:12 +00:00
Martin v. Löwis e920f0d340 Reformulate 42903 using an if statement. 2006-03-07 23:59:33 +00:00
Georg Brandl 516999e6e2 Fix bug introduced in rev. 42884. 2006-03-07 20:56:02 +00:00
Georg Brandl 622927b850 Bug #1432525: os.listdir now releases the GIL while calling
readdir().
2006-03-07 12:48:03 +00:00
Martin v. Löwis 725507b52e Change int to Py_ssize_t in several places.
Add (int) casts to silence compiler warnings.
Raise Python exceptions for overflows.
2006-03-07 12:08:51 +00:00
Tim Peters 67d70eb957 Repair mangled code in the Windows flavor of
posix__getfullpathname().

In partial answer to the now-deleted XXX comment:

	/* XXX(twouters) Why use 'et#' here at all? insize isn't used */

`insize` is an input parameter too, and it was left uninitialized,
leading to seemingly random failures.
2006-03-01 04:35:45 +00:00
Thomas Wouters 68bc4f9ae5 Py_ssize_t-ify. 2006-03-01 01:05:10 +00:00
Hye-Shik Chang d69e034571 Fix a build problem introduced by r42230. 2006-02-19 16:22:22 +00:00
Georg Brandl f4f4415a18 Patch #1393157: os.startfile() now has an optional argument to specify
a "command verb" to invoke on the file.
2006-02-18 22:29:33 +00:00
Martin v. Löwis 18e165558b Merge ssize_t branch. 2006-02-15 17:27:45 +00:00
Martin v. Löwis 14694662d5 Drop C library for stat/fstat on Windows. 2006-02-03 12:54:16 +00:00
Neal Norwitz 1ac754fa10 Check return result from Py_InitModule*(). This API can fail.
Probably should be backported.
2006-01-19 06:09:39 +00:00
Neal Norwitz 30b5c5d011 Fix SF bug #1072182, problems with signed characters.
Most of these can be backported.
2005-12-19 06:05:18 +00:00
Georg Brandl a13c2446dc Bug #869197: setgroups rejects long integer argument 2005-11-22 19:30:31 +00:00
Georg Brandl e9f8ec98d4 Commit memory leaking fix. 2005-09-25 06:16:40 +00:00
Neal Norwitz 3efd0a1e86 Remove unnecessary/extra parens when returning a value. 2005-09-19 06:45:53 +00:00
Neal Norwitz 24b3c22985 Forward port fixes for problems reported by valgrind 2005-09-19 06:43:44 +00:00
Georg Brandl 402b53d43f bug [ 1007046 ] os.startfile() doesn't accept Unicode filenames 2005-09-14 20:51:40 +00:00
Martin v. Löwis f09582eeda Correct definition of ST_GEN_IDX. 2005-08-14 21:42:34 +00:00
Martin v. Löwis ebd9d5ba1a Patch #1180695: Implement nanosecond stat resolution on FreeBSD,
add st_gen, st_birthtime.
2005-08-09 15:00:59 +00:00
Michael W. Hudson b89638148b Fix bug
[ 1232517 ] OverflowError in time.utime() causes strange traceback

A needed error check was missing.

(Actually, this error check may only have become necessary in fairly
recent Python, not sure).

Backport candidate.
2005-07-05 15:21:58 +00:00
Hye-Shik Chang 5f937a7b8b Patch #1212117: Add optional attribute st_flags to os.stat_result
when the member is available on the platform. (Contributed by
Diego Petteno)
2005-06-02 13:09:30 +00:00
Skip Montanaro 5ff1492720 Add O_SHLOCK & O_EXLOCK. Closes patch #1103951. 2005-05-16 02:42:22 +00:00
Martin v. Löwis b60ae99601 Convert file names of posix.access according to the file system encoding. 2005-03-08 09:10:29 +00:00
Michael W. Hudson 9867ced6c2 Fix
[ 1077106 ] Negative numbers to os.read() cause segfault

Sorry for sitting on this for so long!  Is there a chance it could
make 2.3.5?
2005-01-31 17:01:59 +00:00
Martin v. Löwis fe33d0ba87 Default stat_float_times to true. 2005-01-16 08:57:39 +00:00
Andrew MacIntyre a3be258477 fix unterminated comment 2004-12-18 09:51:05 +00:00
Andrew MacIntyre a4a8afb4e1 OS/2 specific fixes related to SF bug # 1003471.
Also revise a related function to minimise file handle/pipe leakage
and improve reliability.
2004-12-12 08:30:51 +00:00
Anthony Baxter 8a560dee72 Patch 977343, Solaris likes sys/loadavg.h. Added support for sys/loadavg.h
detection to configure &c.
2004-10-13 15:30:56 +00:00
Anthony Baxter 9ceaa72ebe Patch #975056 - fixes for restartable signals on *BSD. In addition,
a few remaining calls to signal() were converted to PyOS_setsig().
2004-10-13 14:48:50 +00:00
Armin Rigo b6aa856f25 Patch #1009075, bug #952953: allow execve with empty 2nd argument 2004-09-27 19:54:33 +00:00
Tim Peters d311538a93 win32_urandom(): There's no need to copy the generated byte string, so
don't.
2004-08-30 17:36:46 +00:00
Tim Peters 9b279a8df4 win32_urandom(): pass the function name to PyArg_ParseTuple, for better
error msgs.
2004-08-30 17:10:53 +00:00
Tim Peters 51eba6115d win32_urandom(): Raise ValueError if the argument is negative. 2004-08-30 17:08:02 +00:00
Tim Peters 4ad8217ae9 win32_urandom(): Rewrite to Python C standards (hard tabs, function name
in first column, no parens around return value).
2004-08-30 17:02:04 +00:00
Martin v. Löwis dc3883f671 Patch #934711: Expose platform-specific entropy. 2004-08-29 15:46:35 +00:00
Martin v. Löwis 969297f488 Return unicode strings from _getfullpathname even on W9X. Fixes #924703 . 2004-06-15 18:49:58 +00:00
Neal Norwitz 2adf210993 Ensure path is initialized to prevent freeing random memory
(reported by Thomas Heller).  If have_unicode_filename is set,
path looks like it will not be used, so there's no need to free it.
2004-06-09 01:46:02 +00:00
Neal Norwitz 9665271f92 Plug a few memory leaks in utime(). path is allocated from within
PyArg_ParseTuple() since the format is "et"  This change should
be reviewed carefully.

Bugfix candidate.
2004-06-06 20:40:27 +00:00
Martin v. Löwis d8948725d2 Patch #954115: Fix os.stat handling of UNC roots.
Will backport to 2.3.
2004-06-02 09:57:56 +00:00
Mark Hammond 2d5914b17e Fix [ 947405 ] os.utime() raises bad exception for unicode filenames 2004-05-04 08:10:37 +00:00
Andrew MacIntyre 69e18c9344 OS/2 has support for spawnvp() and spawnvpe() in the C libraries supplied
with major C compilers (VACPP, EMX+gcc and [Open]Watcom).

Also tidy up the export of spawn*() symbols in the os module to match what
is found/implemented.
2004-04-04 07:11:43 +00:00
Andrew MacIntyre da4d6cb573 OS/2 VACPP build updates/fixes 2004-03-29 11:53:38 +00:00
Neal Norwitz 94f1d71d70 Fix docstrings to mention the correct function 2004-02-16 01:26:34 +00:00
Skip Montanaro 7befb9966e remove support for missing ANSI C header files (limits.h, stddef.h, etc). 2004-02-10 16:50:21 +00:00
Skip Montanaro ce59c04127 Remove support for SunOS 4.
Remove BAD_EXEC_PROTOYPE (leftover from IRIX 4 demolition).
2004-01-17 14:19:44 +00:00
Andrew M. Kuchling 8135fd5365 Make parameter names in docstring more mnemonic 2004-01-16 13:18:42 +00:00
Hye-Shik Chang 2b2c97356f FIx unicodefilename support of posix.uname(). This fixes test_unicode_file
failure on FreeBSD.
2004-01-04 13:54:25 +00:00
Mark Hammond 817c929bba Fix [ 846133 ] os.chmod/os.utime/shutil do not work with unicode filenames 2003-12-03 01:22:38 +00:00