| Commit message (Collapse) | Author | Age | Files | Lines | |
|---|---|---|---|---|---|
| * | Issue #15989: Fix several occurrences of integer overflow | Serhiy Storchaka | 2013-01-19 | 1 | -4/+4 |
| | | | | | | | | when result of PyInt_AsLong() or PyLong_AsLong() narrowed to int without checks. This is a backport of changesets 13e2e44db99d and 525407d89277. | ||||
| * | get the core to compile --disable-unicode | Benjamin Peterson | 2013-01-02 | 1 | -1/+3 |
| | | |||||
| * | Fixes issue #12268 for file readline, readlines and read() and readinto methods. | Gregory P. Smith | 2012-06-26 | 1 | -4/+61 |
| | | | | | | | They no longer lose data when an underlying read system call is interrupted. IOError is no longer raised due to a read system call returning EINTR from within these methods. | ||||
| * | Issue #14505: Fix file descriptor leak when deallocating file objects ↵ | Antoine Pitrou | 2012-04-05 | 1 | -1/+2 |
| | | | | | created with PyFile_FromString(). | ||||
| * | #14161: fix compile error under Windows. | Ezio Melotti | 2012-03-11 | 1 | -1/+2 |
| | | |||||
| * | #14161: fix the __repr__ of file objects to escape the file name. | Ezio Melotti | 2012-03-11 | 1 | -4/+10 |
| | | |||||
| * | Issue #13159: Replace FileIO's quadratic-time buffer growth algorithm with a ↵ | Nadeem Vawda | 2011-10-13 | 1 | -15/+4 |
| | | | | | | | linear-time one. Also fix the builtin file class and the bz2 module, which used the same algorithm. | ||||
| * | Issue #7732: Fix a crash on importing a module if a directory has the same name | Victor Stinner | 2011-09-23 | 1 | -13/+19 |
| | | | | | | | | | than a Python module (e.g. "__init__.py"): don't close the file twice. PyFile_FromFile() does also close the file if PyString_FromString() failed. It did already close the file on fill_file_fields() error (e.g. if the file is a directory). | ||||
| * | Issue #9295: Fix a crash under Windows when calling close() on a file | Antoine Pitrou | 2010-10-28 | 1 | -0/+6 |
| | | | | | object with custom buffering from two threads at once. | ||||
| * | iterators passed to writelines() can close their files; don't segfault #10125 | Benjamin Peterson | 2010-10-16 | 1 | -0/+5 |
| | | |||||
| * | Issue #4947: The write() method of sys.stdout and sys.stderr uses their | Victor Stinner | 2010-09-08 | 1 | -4/+33 |
| | | | | | | encoding and errors attributes instead of using utf-8 in strict mode, to get the same behaviour than the print statement. | ||||
| * | Issue #7079: Fix a possible crash when closing a file object while using | Antoine Pitrou | 2010-05-17 | 1 | -2/+4 |
| | | | | | it from another thread. Patch by Daniel Stutzbach. | ||||
| * | Untabify C files. Will watch buildbots. | Antoine Pitrou | 2010-05-09 | 1 | -2002/+2002 |
| | | |||||
| * | more _PyString_Resize error checking | Benjamin Peterson | 2010-04-03 | 1 | -8/+10 |
| | | |||||
| * | #7706: DONT_HAVE_ERRNO_H is no longer defined by configure (after rev.46819). | Andrew M. Kuchling | 2010-02-22 | 1 | -1/+1 |
| | | |||||
| * | Issue #5677: Explicitly forbid write operations on read-only file objects, | Antoine Pitrou | 2010-02-05 | 1 | -0/+32 |
| | | | | | | | and read operations on write-only file objects. On Windows, the system C library would return a bogus result; on Solaris, it was possible to crash the interpreter. Patch by Stefan Krah. | ||||
| * | Issue #6368: Fixed unused variable warning on Unix. | Hirokazu Yamamoto | 2009-06-29 | 1 | -0/+2 |
| | | |||||
| * | Issue #4856: Remove checks for win NT. | Hirokazu Yamamoto | 2009-06-28 | 1 | -19/+11 |
| | | |||||
| * | Issue #3527: Removed Py_WIN_WIDE_FILENAMES which is not used any more. | Hirokazu Yamamoto | 2009-05-17 | 1 | -1/+1 |
| | | |||||
| * | issue 4804: Provide checks for the format string of strftime, and for the ↵ | Kristján Valur Jónsson | 2009-02-04 | 1 | -1/+88 |
| | | | | | "mode" string of fopen on Windows. These strings are user provided from python and so we can avoid invoking the C runtime invalid parameter handler by first checking that they are valid. | ||||
| * | #4764 set IOError.filename when trying to open a directory on POSIX platforms | Benjamin Peterson | 2008-12-29 | 1 | -2/+2 |
| | | |||||
| * | #3965: on Windows, open() crashes if the filename or the mode is invalid, | Amaury Forgeot d'Arc | 2008-09-25 | 1 | -4/+11 |
| | | | | | | | and if the filename is a unicode string. Reviewed by Martin von Loewis. | ||||
| * | Issue #3139: Make buffer-interface thread-safe wrt. PyArg_ParseTuple, | Martin v. Löwis | 2008-08-12 | 1 | -2/+16 |
| | | | | | | | | by denying s# to parse objects that have a releasebuffer procedure, and introducing s*. More module might need to get converted to use s*. | ||||
| * | More reverting of r63675 per the mailing list discussions. This restores | Gregory P. Smith | 2008-06-10 | 1 | -3/+3 |
| | | | | | | occurances of PyBytes_ in the code to their original PyString_ names. The bytesobject.c file will be renamed back to stringobject.c in a future checkin. | ||||
| * | This reverts r63675 based on the discussion in this thread: | Gregory P. Smith | 2008-06-09 | 1 | -54/+54 |
| | | | | | | | | http://mail.python.org/pipermail/python-dev/2008-June/079988.html Python 2.6 should stick with PyString_* in its codebase. The PyBytes_* names in the spirit of 3.0 are available via a #define only. See the email thread. | ||||
| * | New environment variable PYTHONIOENCODING. | Martin v. Löwis | 2008-06-01 | 1 | -3/+32 |
| | | |||||
| * | Renamed PyString to PyBytes | Christian Heimes | 2008-05-26 | 1 | -56/+56 |
| | | |||||
| * | #2353: raise Py3k warning in file.xreadlines(). | Georg Brandl | 2008-05-17 | 1 | -3/+12 |
| | | |||||
| * | A little reformating of Py3k warnings | Benjamin Peterson | 2008-04-27 | 1 | -2/+3 |
| | | |||||
| * | Use PyErr_WarnPy3k throughout | Benjamin Peterson | 2008-04-27 | 1 | -6/+2 |
| | | |||||
| * | Make file objects as thread safe as the underlying libc FILE* implementation. | Gregory P. Smith | 2008-04-06 | 1 | -81/+164 |
| | | | | | | | | | | | | close() will now raise an IOError if any operations on the file object are currently in progress in other threads. Most code was written by Antoine Pitrou (pitrou). Additional testing, documentation and test suite cleanup done by me (gregory.p.smith). Fixes issue 815646 and 595601 (as well as many other bugs and references to this problem dating back to the dawn of Python). | ||||
| * | #2348: add py3k warning for file.softspace. | Georg Brandl | 2008-03-21 | 1 | -2/+34 |
| | | |||||
| * | Remove all traces of HAVE_STRERROR. | Brett Cannon | 2008-03-18 | 1 | -8/+0 |
| | | | | | | The removal of strerror.c led to the function check being removed from configure.in. | ||||
| * | Fix the IOError message text when opening a file with an invalid filename. | Gregory P. Smith | 2008-03-18 | 1 | -2/+5 |
| | | | | | Error reported by Ilan Schnell. | ||||
| * | #2067: file.__exit__() now calls subclasses' close() method. | Georg Brandl | 2008-02-23 | 1 | -2/+2 |
| | | |||||
| * | static PyObject* variables should use PyString_InternFromString() instead of ↵ | Christian Heimes | 2008-01-28 | 1 | -1/+1 |
| | | | | | PyObject_FromString() to store a python string in a function level static var. | ||||
| * | #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and ↵ | Christian Heimes | 2007-12-19 | 1 | -1/+1 |
| | | | | | Py_REFCNT. Macros for b/w compatibility are available. | ||||
| * | Note that open() is the preferred way to open files (issue 1510). | Skip Montanaro | 2007-12-08 | 1 | -1/+2 |
| | | |||||
| * | Patch # 188 by Philip Jenvey. | Guido van Rossum | 2007-09-22 | 1 | -0/+1 |
| | | | | | | Make tell() mark CRLF as a newline. With unit test. | ||||
| * | Add a bunch of GIL release/acquire points in tp_print implementations and for | Brett Cannon | 2007-09-17 | 1 | -0/+2 |
| | | | | | | | PyObject_Print(). Closes issue #1164. | ||||
| * | PEP 3123: Provide forward compatibility with Python 3.0, while keeping | Martin v. Löwis | 2007-07-21 | 1 | -3/+2 |
| | | | | | | backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and PyVarObject_HEAD_INIT. | ||||
| * | Export function sanitize_the_mode from fileobject.c as ↵ | Kristján Valur Jónsson | 2007-04-26 | 1 | -8/+7 |
| | | | | | _PyFile_SanitizeMode(). Use this function in posixmodule.c when implementing fdopen(). This fixes test_subprocess.py for a VisualStudio 2005 compile. | ||||
| * | SF patch #1630975: Fix crash when replacing sys.stdout in sitecustomize | Thomas Wouters | 2007-01-23 | 1 | -0/+2 |
| | | | | | | | | | | | | When running the interpreter in an environment that would cause it to set stdout/stderr/stdin's encoding, having a sitecustomize that would replace them with something other than PyFile objects would crash the interpreter. Fix it by simply ignoring the encoding-setting for non-files. This could do with a test, but I can think of no maintainable and portable way to test this bug, short of adding a sitecustomize.py to the buildsystem and have it always run with it (hmmm....) | ||||
| * | Bug #1067760: Deprecate passing floats to file.seek. | Martin v. Löwis | 2006-11-12 | 1 | -4/+17 |
| | | |||||
| * | Forward-port of r52136,52138: a review of overflow-detecting code. | Armin Rigo | 2006-10-04 | 1 | -2/+6 |
| | | | | | | | | | | | | | | | | | | | | | | | | * unified the way intobject, longobject and mystrtoul handle values around -sys.maxint-1. * in general, trying to entierely avoid overflows in any computation involving signed ints or longs is extremely involved. Fixed a few simple cases where a compiler might be too clever (but that's all guesswork). * more overflow checks against bad data in marshal.c. * 2.5 specific: fixed a number of places that were still confusing int and Py_ssize_t. Some of them could potentially have caused "real-world" breakage. * list.pop(x): fixing overflow issues on x was messy. I just reverted to PyArg_ParseTuple("n"), which does the right thing. (An obscure test was trying to give a Decimal to list.pop()... doesn't make sense any more IMHO) * trying to write a few tests... | ||||
| * | Make sure memory is properly cleaned up in file_init. | Brett Cannon | 2006-08-31 | 1 | -1/+1 |
| | | | | | Backport candidate. | ||||
| * | Fix a couple of ssize-t issues reported by Alexander Belopolsky on python-dev | Neal Norwitz | 2006-08-21 | 1 | -1/+1 |
| | | |||||
| * | Stop INCREFing name, then checking if it's NULL. name (f_name) should never | Neal Norwitz | 2006-07-17 | 1 | -3/+6 |
| | | | | | | | be NULL so assert it. Fix one place where we could have passed NULL. Reported by Klocwork #66. | ||||
| * | Handle a NULL name properly. | Neal Norwitz | 2006-07-16 | 1 | -3/+3 |
| | | | | | Reported by Klocwork #67 | ||||
| * | Fix build problems with the platform SDK on windows. It is not sufficient ↵ | Kristján Valur Jónsson | 2006-07-03 | 1 | -1/+1 |
| | | | | | to test for the C compiler version when determining if we have the secure CRT from microsoft. Must test with an undocumented macro, __STDC_SECURE_LIB__ too. | ||||
