summaryrefslogtreecommitdiffstats
path: root/Modules/main.c
Commit message (Collapse)AuthorAgeFilesLines
* Fixed formatting comman-line usage message.Serhiy Storchaka2015-12-301-4/+4
|
* Issue #23752: _Py_fstat() is now responsible to raise the Python exceptionVictor Stinner2015-03-301-2/+4
| | | | Add _Py_fstat_noraise() function when a Python exception is not welcome.
* Back-out wcstok deprecation suppression and updates calls to use wcstok_s.Steve Dower2015-02-261-3/+3
|
* Issue #23152: Implement _Py_fstat() to support files larger than 2 GB on ↵Steve Dower2015-02-211-3/+2
| | | | | | Windows. fstat() may fail with EOVERFLOW on files larger than 2 GB because the file size type is an signed 32-bit integer.
* Issue #20597: Remove unused definition of PATH_MAX on Windows, MAXPATHLEN isVictor Stinner2014-11-051-1/+0
| | | | now preferred. Patch written by Jeffrey Armstrong.
* Issue #18395: Rename ``_Py_char2wchar()`` to :c:func:`Py_DecodeLocale`, renameVictor Stinner2014-08-011-2/+2
| | | | | ``_Py_wchar2char()`` to :c:func:`Py_EncodeLocale`, and document these functions.
* Issue #20355: -W command line options now have higher priority than the ↵Antoine Pitrou2014-04-281-1/+18
| | | | PYTHONWARNINGS environment variable. Patch by Arfrever.
* Issue #16136: Remove VMS support and VMS-related codeChristian Heimes2013-12-211-29/+0
|
* Issue #19512, #19515: remove shared identifiers, move identifiers where theyVictor Stinner2013-11-071-1/+1
| | | | | | | are used. Move also _Py_IDENTIFIER() defintions to the top in modified files to remove identifiers duplicated in the same file.
* Issue #19512: add some common identifiers to only create common strings once,Victor Stinner2013-11-061-1/+1
| | | | | | | instead of creating temporary Unicode string objects Add also more identifiers in pythonrun.c to avoid temporary Unicode string objets for the interactive interpreter.
* Issue #18571: Implementation of the PEP 446: file descriptors and file handlesVictor Stinner2013-08-271-1/+1
| | | | | are now created non-inheritable; add functions os.get/set_inheritable(), os.get/set_handle_inheritable() and socket.socket.get/set_inheritable().
* Issue #16400: Add command line option for isolated mode.Christian Heimes2013-08-101-1/+8
| | | | | | | | | | -I Run Python in isolated mode. This also implies -E and -s. In isolated mode sys.path contains neither the script’s directory nor the user’s site-packages directory. All PYTHON* environment variables are ignored, too. Further restrictions may be imposed to prevent the user from injecting malicious code.
* #16937: merge with 3.3.Ezio Melotti2013-07-251-1/+2
|\
| * #16937: document that stdin is always buffered, even when -u is used. Patch ↵Ezio Melotti2013-07-251-1/+2
| | | | | | | | by Elena Oat.
* | Issue #18408: handle PySys_GetObject() failure, raise a RuntimeErrorVictor Stinner2013-07-161-1/+3
| |
* | Issue #18338: `python --version` now prints version string to stdout, andSerhiy Storchaka2013-07-111-1/+1
| | | | | | | | not to stderr. Patch by Berker Peksag and Michael Dickens.
* | Issue #18203: Add _PyMem_RawStrdup() and _PyMem_Strdup()Victor Stinner2013-07-071-2/+2
| | | | | | | | | | Replace strdup() with _PyMem_RawStrdup() or _PyMem_Strdup(), depending if the GIL is held or not.
* | Issue #18203: Replace malloc() with PyMem_RawMalloc() at Python initializationVictor Stinner2013-07-071-7/+7
| | | | | | | | | | | | | | * Replace malloc() with PyMem_RawMalloc() * Replace PyMem_Malloc() with PyMem_RawMalloc() where the GIL is not held. * _Py_char2wchar() now returns a buffer allocated by PyMem_RawMalloc(), instead of PyMem_Malloc()
* | Issue #5845: Enable tab-completion in the interactive interpreter by ↵Antoine Pitrou2013-05-041-0/+28
| | | | | | | | | | | | default, thanks to a new sys.__interactivehook__. (original patch by Éric Araujo)
* | Close #14439: Python now prints the traceback on runpy failure at startup.Victor Stinner2013-04-091-0/+4
| |
* | #16306: merge with 3.3.Ezio Melotti2012-11-231-0/+1
|\ \ | |/
| * #16306: merge with 3.2.Ezio Melotti2012-11-231-0/+1
| |\
| | * #16306: report only the first unknown option and add more tests. Patch by ↵Ezio Melotti2012-11-231-0/+1
| | | | | | | | | | | | Serhiy Storchaka.
* | | #16135: Removal of OS/2 support (posixmodule y platform dependent files)Jesus Cea2012-10-041-5/+1
|/ /
* | Fix for issue 15716: interpreter could crash when PYTHONEXECUTABLE was set ↵Ronald Oussoren2012-08-221-1/+1
|\ \ | |/ | | | | | | | | | | | | | | on Mac OS X. This is due to an off-by-one error: the allocated buffer didn't have room for a NUL character at the end of the mbstowcs result. (merge with 3.2)
| * Fix for issue 15716: interpreter could crash when PYTHONEXECUTABLE was set ↵Ronald Oussoren2012-08-221-1/+1
| | | | | | | | | | | | | | on Mac OS X. This is due to an off-by-one error: the allocated buffer didn't have room for a NUL character at the end of the mbstowcs result.
* | Closes #15307: symlinks now work on OS X with framework Python builds. ↵Vinay Sajip2012-07-171-0/+22
| | | | | | | | Patch by Ronald Oussoren.
* | Fix issue # 15033 - Return the proper exitcode for failure when modules are ↵Senthil Kumaran2012-07-051-1/+1
|\ \ | |/ | | | | invoked using -m switch. Patch contributed by Jeff Knupp
| * Fix issue # 15033 - Return the proper exitcode for failure when modules are ↵Senthil Kumaran2012-07-051-1/+1
| | | | | | | | invoked using -m switch. Patch contributed by Jeff Knupp
* | Issue #14605: Use None in sys.path_importer_cache to represent noBrett Cannon2012-04-271-1/+1
| | | | | | | | finder instead of using some (now non-existent) implicit finder.
* | merge with 3.2Georg Brandl2012-02-211-1/+1
|\ \ | |/
| * merge with 3.2Georg Brandl2012-02-211-3/+3
| |\
| | * Remove reST markup from --help output. Also: O(n**2) is dict construction, ↵Georg Brandl2012-02-211-3/+3
| | | | | | | | | | | | not single insertion.
* | | enable hash randomization by defaultBenjamin Peterson2012-02-211-18/+7
| | |
* | | Fix test failure in test_cmd_line by initializing the hash secret at the ↵Antoine Pitrou2012-02-211-2/+28
|\ \ \ | |/ / | | | | | | earliest point.
| * | Fix test failure in test_cmd_line by initializing the hash secret at the ↵Antoine Pitrou2012-02-211-2/+28
| | | | | | | | | | | | earliest point.
* | | Merge 3.2: Issue #13703 plus some related test suite fixes.Georg Brandl2012-02-201-3/+17
|\ \ \ | |/ /
| * | Merge from 3.1: Issue #13703: add a way to randomize the hash values of ↵Georg Brandl2012-02-201-3/+17
| |\ \ | | |/ | | | | | | | | | | | | | | | | | | | | | basic types (str, bytes, datetime) in order to make algorithmic complexity attacks on (e.g.) web apps much more complicated. The environment variable PYTHONHASHSEED and the new command line flag -R control this behavior.
| | * Issue #13703: add a way to randomize the hash values of basic types (str, ↵Georg Brandl2012-02-201-1/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | bytes, datetime) in order to make algorithmic complexity attacks on (e.g.) web apps much more complicated. The environment variable PYTHONHASHSEED and the new command line flag -R control this behavior.
| | * Merged revisions 87991 via svnmerge fromEli Bendersky2011-01-141-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r87991 | eli.bendersky | 2011-01-14 09:31:14 +0200 (Fri, 14 Jan 2011) | 2 lines Remove call to nonexisting function (relic from Python 2.x) under #ifdef __INSURE__. Issue 9844 ........
| | * Merged revisions 81250-81253 via svnmerge fromVictor Stinner2010-05-171-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r81250 | victor.stinner | 2010-05-17 03:13:37 +0200 (lun., 17 mai 2010) | 2 lines Issue #6697: Fix a crash if code of "python -c code" contains surrogates ........ r81251 | victor.stinner | 2010-05-17 03:26:01 +0200 (lun., 17 mai 2010) | 3 lines PyObject_Dump() encodes unicode objects to utf8 with backslashreplace (instead of strict) error handler to escape surrogates ........ r81252 | victor.stinner | 2010-05-17 10:58:51 +0200 (lun., 17 mai 2010) | 6 lines handle_system_exit() flushs files to warranty the output order PyObject_Print() writes into the C object stderr, whereas PySys_WriteStderr() writes into the Python object sys.stderr. Each object has its own buffer, so call sys.stderr.flush() and fflush(stderr). ........ r81253 | victor.stinner | 2010-05-17 11:33:42 +0200 (lun., 17 mai 2010) | 6 lines Fix refleak in internal_print() introduced by myself in r81251 _PyUnicode_AsDefaultEncodedString() uses a magical PyUnicode attribute to automatically destroy PyUnicode_EncodeUTF8() result when the unicode string is destroyed. ........
| | * Recorded merge of revisions 81032 via svnmerge fromAntoine Pitrou2010-05-091-483/+483
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ................ r81032 | antoine.pitrou | 2010-05-09 17:52:27 +0200 (dim., 09 mai 2010) | 9 lines Recorded merge of revisions 81029 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r81029 | antoine.pitrou | 2010-05-09 16:46:46 +0200 (dim., 09 mai 2010) | 3 lines Untabify C files. Will watch buildbots. ........ ................
| | * Merged revisions 78872 via svnmerge fromVictor Stinner2010-03-211-4/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ................ r78872 | victor.stinner | 2010-03-12 15:45:56 +0100 (ven., 12 mars 2010) | 12 lines Merged revisions 78826 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r78826 | victor.stinner | 2010-03-10 23:30:19 +0100 (mer., 10 mars 2010) | 5 lines Issue #3137: Don't ignore errors at startup, especially a keyboard interrupt (SIGINT). If an error occurs while importing the site module, the error is printed and Python exits. Initialize the GIL before importing the site module. ........ ................
| | * Merged revisions 75571,75576-75577 via svnmerge fromAntoine Pitrou2009-10-201-29/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ................ r75571 | antoine.pitrou | 2009-10-20 23:52:47 +0200 (mar., 20 oct. 2009) | 11 lines Merged revisions 75570 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r75570 | antoine.pitrou | 2009-10-20 23:29:37 +0200 (mar., 20 oct. 2009) | 6 lines Issue #1722344: threading._shutdown() is now called in Py_Finalize(), which fixes the problem of some exceptions being thrown at shutdown when the interpreter is killed. Patch by Adam Olsen. ........ ................ r75576 | antoine.pitrou | 2009-10-21 00:02:29 +0200 (mer., 21 oct. 2009) | 10 lines Merged revisions 75574 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r75574 | antoine.pitrou | 2009-10-20 23:59:25 +0200 (mar., 20 oct. 2009) | 4 lines Test wouldn't work in debug mode. We probably need a function in test_support to handle this. ........ ................ r75577 | antoine.pitrou | 2009-10-21 00:05:38 +0200 (mer., 21 oct. 2009) | 3 lines Another futile error in the previous commit :-( ................
| | * Merged revisions 74010,74034,74054 via svnmerge fromGeorg Brandl2009-08-131-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://svn.python.org/python/branches/py3k ................ r74010 | r.david.murray | 2009-07-15 16:16:54 +0200 (Mi, 15 Jul 2009) | 2 lines PEP-8-ify r73389. ................ r74034 | alexandre.vassalotti | 2009-07-17 07:35:59 +0200 (Fr, 17 Jul 2009) | 2 lines The output() function takes only one string argument. ................ r74054 | alexandre.vassalotti | 2009-07-17 10:31:44 +0200 (Fr, 17 Jul 2009) | 14 lines Merged revisions 74051-74052 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r74051 | alexandre.vassalotti | 2009-07-17 03:54:23 -0400 (Fri, 17 Jul 2009) | 2 lines Initialize variables in PyCurses_getsyx() to avoid compiler warnings. ........ r74052 | alexandre.vassalotti | 2009-07-17 04:09:04 -0400 (Fri, 17 Jul 2009) | 3 lines Fix GCC warning about fprintf used without a string literal and without format arguments. ........ ................
* | | Issue #13560: Locale codec functions use the classic "errors" parameter,Victor Stinner2011-12-171-1/+1
| | | | | | | | | | | | | | | | | | instead of surrogateescape So it would be possible to support more error handlers later.
* | | Add PyUnicode_DecodeLocaleAndSize() and PyUnicode_DecodeLocale()Victor Stinner2011-12-161-8/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PyUnicode_DecodeLocaleAndSize() and PyUnicode_DecodeLocale() decode a string from the current locale encoding * _Py_char2wchar() writes an "error code" in the size argument to indicate if the function failed because of memory allocation failure or because of a decoding error. The function doesn't write the error message directly to stderr. * Fix time.strftime() (if wcsftime() is missing): decode strftime() result from the current locale encoding, not from the filesystem encoding.
* | | Issue #10350: Read and save errno before calling a function which might ↵Antoine Pitrou2011-12-161-1/+2
|\ \ \ | |/ / | | | | | | | | | | | | overwrite it. Original patch by Hallvard B Furuseth.
| * | Issue #10350: Read and save errno before calling a function which might ↵Antoine Pitrou2011-12-161-1/+2
| | | | | | | | | | | | | | | | | | overwrite it. Original patch by Hallvard B Furuseth.
* | | Issue #11918: OS/2 and VMS are no more supported because of the lack ofVictor Stinner2011-04-261-0/+1
| | | | | | | | | | | | maintainer.