Georg Brandl
f004d9dc84
Merged revisions 73206,73232,73299,73683,74020,74185,74544,74643,74647,74817,74838-74839,74865,74946,75402,75459,75604,75696 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r73206 | georg.brandl | 2009-06-04 11:15:12 +0200 (Do, 04 Jun 2009) | 1 line
#3584 : ignore trailing newlines when placing the caret for a SyntaxError location.
........
r73232 | georg.brandl | 2009-06-04 20:59:58 +0200 (Do, 04 Jun 2009) | 1 line
Add test for #3684 .
........
r73299 | georg.brandl | 2009-06-08 20:41:36 +0200 (Mo, 08 Jun 2009) | 1 line
Typo fix.
........
r73683 | georg.brandl | 2009-06-29 16:44:49 +0200 (Mo, 29 Jun 2009) | 1 line
Fix error handling in PyCode_Optimize, by Alexander Schremmer at EuroPython sprint.
........
r74020 | georg.brandl | 2009-07-16 09:18:07 +0200 (Do, 16 Jul 2009) | 1 line
#5910 : fix kqueue for calls with more than one event.
........
r74185 | georg.brandl | 2009-07-23 11:17:09 +0200 (Do, 23 Jul 2009) | 1 line
Fix the "pylocals" gdb command.
........
r74544 | georg.brandl | 2009-08-24 19:12:30 +0200 (Mo, 24 Aug 2009) | 1 line
#6775 : fix python.org URLs in README.
........
r74643 | georg.brandl | 2009-09-04 08:59:20 +0200 (Fr, 04 Sep 2009) | 2 lines
Issue #2666 : Handle BROWSER environment variable properly for unknown browser names in the webbrowser module.
........
r74647 | georg.brandl | 2009-09-04 10:17:04 +0200 (Fr, 04 Sep 2009) | 2 lines
Issue #5275 : In Cookie's Cookie.load(), properly handle non-string arguments as documented.
........
r74817 | georg.brandl | 2009-09-16 11:05:11 +0200 (Mi, 16 Sep 2009) | 1 line
Make deprecation notices as visible as warnings are right now.
........
r74838 | georg.brandl | 2009-09-16 18:22:12 +0200 (Mi, 16 Sep 2009) | 1 line
Remove some more boilerplate from the actual tests in test_pdb.
........
r74839 | georg.brandl | 2009-09-16 18:36:39 +0200 (Mi, 16 Sep 2009) | 1 line
Make the pdb displayhook compatible with the standard displayhook: do not print Nones. Add a test for that.
........
r74865 | georg.brandl | 2009-09-17 09:49:37 +0200 (Do, 17 Sep 2009) | 1 line
#6912 : add "with" block support to pindent.
........
r74946 | georg.brandl | 2009-09-19 10:43:16 +0200 (Sa, 19 Sep 2009) | 1 line
Update bug tracker reference.
........
r75402 | georg.brandl | 2009-10-14 17:51:48 +0200 (Mi, 14 Okt 2009) | 1 line
#7125 : fix typo.
........
r75459 | georg.brandl | 2009-10-17 10:57:43 +0200 (Sa, 17 Okt 2009) | 1 line
Fix refleaks in _ctypes PyCSimpleType_New, which fixes the refleak seen in test___all__.
........
r75604 | georg.brandl | 2009-10-22 13:36:50 +0200 (Do, 22 Okt 2009) | 1 line
Fix stylesheet for multi-paragraph impl-details.
........
r75696 | georg.brandl | 2009-10-25 21:25:43 +0100 (So, 25 Okt 2009) | 1 line
Fix a demo.
........
2009-10-27 15:39:53 +00:00
Georg Brandl
2f3bd8364a
#3852 : fix some select.kqueue and kevent docs.
2008-09-21 07:14:44 +00:00
Gregory P. Smith
0470bab697
Issue #2620 : Overflow checking when allocating or reallocating memory
...
was not always being done properly in some python types and extension
modules. PyMem_MALLOC, PyMem_REALLOC, PyMem_NEW and PyMem_RESIZE have
all been updated to perform better checks and places in the code that
would previously leak memory on the error path when such an allocation
failed have been fixed.
2008-07-22 04:46:32 +00:00
Gregory P. Smith
dd96db63f6
This reverts r63675 based on the discussion in this thread:
...
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.
2008-06-09 04:58:54 +00:00
Christian Heimes
593daf545b
Renamed PyString to PyBytes
2008-05-26 12:51:38 +00:00
Georg Brandl
018a3622e8
Fix and simplify error handling, silencing a compiler warning.
2008-03-26 12:57:47 +00:00
Andrew M. Kuchling
a8c3f2b6b6
Minor docstring typos
2008-03-26 00:16:50 +00:00
Christian Heimes
0e9ab5f2f0
Applied patch #1657 epoll and kqueue wrappers for the select module
...
The patch adds wrappers for the Linux epoll syscalls and the BSD kqueue syscalls. Thanks to Thomas Herve and the Twisted people for their support and help.
TODO: Finish documentation documentation
2008-03-21 23:49:44 +00:00
Christian Heimes
e93237dfcc
#1629 : Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and Py_REFCNT. Macros for b/w compatibility are available.
2007-12-19 02:37:44 +00:00
Martin v. Löwis
6819210b9e
PEP 3123: Provide forward compatibility with Python 3.0, while keeping
...
backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and
PyVarObject_HEAD_INIT.
2007-07-21 06:55:02 +00:00
Neal Norwitz
2a30cd0ef0
Patch #1516912 : improve Modules support for OpenVMS.
2006-07-10 01:18:57 +00:00
Martin v. Löwis
0e8bd7e1cc
Patch #1495999 : Part two of Windows CE changes.
...
- update header checks, using autoconf
- provide dummies for getenv, environ, and GetVersion
- adjust MSC_VER check in socketmodule.c
2006-06-10 12:23:46 +00:00
Georg Brandl
96a8c3954c
Make use of METH_O and METH_NOARGS where possible.
...
Use Py_UnpackTuple instead of PyArg_ParseTuple where possible.
2006-05-29 21:04:52 +00:00
Ronald Oussoren
32fd16ece9
Patch 1471761 - test for broken poll at runtime
...
This patch checks if poll is broken when the select module is loaded instead
of doing so at configure-time. This functionality is only active on Mac OS X.
2006-04-23 12:36:23 +00:00
Martin v. Löwis
18e165558b
Merge ssize_t branch.
2006-02-15 17:27:45 +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
0f46bbf781
Bug #1346533 , select.poll() doesn't raise an error if timeout > sys.maxint
...
Need to check return result of PyInt_AsLong()
Will backport.
2005-11-03 05:00:25 +00:00
Andrew M. Kuchling
e5dd162a07
[Bug #923315 ] Produce correct result on AIX
2004-08-07 17:21:27 +00:00
Nicholas Bastin
e62c5c88f1
Added configure check for broken poll() on some unix systems (MacOS X 10.3)
...
Fixes SF Bug #850981
2004-03-21 23:45:42 +00:00
Raymond Hettinger
8ae4689657
Simplify and speedup uses of Py_BuildValue():
...
* Py_BuildValue("(OOO)",a,b,c) --> PyTuple_Pack(3,a,b,c)
* Py_BuildValue("()",a) --> PyTuple_New(0)
* Py_BuildValue("O", a) --> Py_INCREF(a)
2003-10-12 19:09:37 +00:00
Brett Cannon
62dba4c277
select.select() now accepts a sequence (as defined by PySequence_Fast()) for
...
its first three arguments.
Closes RFE #798046 .
2003-09-10 19:37:42 +00:00
Tim Peters
5f322d3dfd
SF bug 684667: Modules/selectmodule.c returns NULL without exception set.
...
select_select() didn't set an exception in the SELECT_USES_HEAP case when
malloc() returned NULL.
2003-02-11 17:18:58 +00:00
Neil Schemenauer
47ec6c0790
Don't use PyNumber_Float() since it's is nearly useless. Instead, rely on
...
PyFloat_AsDouble to generate a good error message.
2002-11-18 16:02:29 +00:00
Walter Dörwald
08c4cc4127
Use PyInt_AsLong instead of PyInt_AS_LONG after the call to
...
PyNumber_Int, because now PyNumber_Int might return a long,
and PyInt_AsLong can handle that, whereas PyInt_AS_LONG can't.
This closes SF bug #629989 .
2002-11-12 11:42:20 +00:00
Thomas Heller
7bdabe67a3
I did fix too much - including winsock.h is sufficient.
2002-09-24 17:03:26 +00:00
Thomas Heller
106f4c7ba7
On Windows, call WSAGetLastError() to retrieve the error number.
...
Bugfix candidate, will backport to release22-maint myself.
2002-09-24 16:51:00 +00:00
Neal Norwitz
77c72bb323
SF patch #577031 , remove PyArg_Parse() since it's deprecated
2002-07-28 15:12:10 +00:00
Mark Hammond
62b1ab1b31
Replace DL_IMPORT with PyMODINIT_FUNC and remove "/export:init..." link
...
command line for Windows builds. This should allow MSVC to import and
build the Python MSVC6 project files without error.
2002-07-23 06:31:15 +00:00
Tim Peters
0c32279626
Removed more stray instances of statichere, but left _sre.c alone.
2002-07-17 16:49:03 +00:00
Jeremy Hylton
938ace69a0
staticforward bites the dust.
...
The staticforward define was needed to support certain broken C
compilers (notably SCO ODT 3.0, perhaps early AIX as well) botched the
static keyword when it was used with a forward declaration of a static
initialized structure. Standard C allows the forward declaration with
static, and we've decided to stop catering to broken C compilers. (In
fact, we expect that the compilers are all fixed eight years later.)
I'm leaving staticforward and statichere defined in object.h as
static. This is only for backwards compatibility with C extensions
that might still use it.
XXX I haven't updated the documentation.
2002-07-17 16:30:39 +00:00
Martin v. Löwis
14f8b4cfcb
Patch #568124 : Add doc string macros.
2002-06-13 20:33:02 +00:00
Neal Norwitz
3e12905e03
Remove unused static function
2002-05-31 21:47:02 +00:00
Fred Drake
4baedc1d9b
Use the PyModule_Add*() APIs instead of manipulating the module dict
...
directly.
2002-04-01 14:53:37 +00:00
Andrew MacIntyre
7bf6833e17
OS/2 EMX port changes (Modules part of patch #450267 ):
...
Modules/
_hotshot.c
dbmmodule.c
fcntlmodule.c
main.c
pwdmodule.c
readline.c
selectmodule.c
signalmodule.c
termios.c
timemodule.c
unicodedata.c
2002-03-03 02:59:16 +00:00
Martin v. Löwis
cdc4451222
Include <unistd.h> in Python.h. Fixes #500924 .
2002-01-12 11:05:12 +00:00
Guido van Rossum
146483964e
Patch supplied by Burton Radons for his own SF bug #487390 : Modifying
...
type.__module__ behavior.
This adds the module name and a dot in front of the type name in every
type object initializer, except for built-in types (and those that
already had this). Note that it touches lots of Mac modules -- I have
no way to test these but the changes look right. Apologies if they're
not. This also touches the weakref docs, which contains a sample type
object initializer. It also touches the mmap test output, because the
mmap type's repr is included in that output. It touches object.h to
put the correct description in a comment.
2001-12-08 18:02:58 +00:00
Guido van Rossum
a0dfc8577d
Fix SF bug #474538 : Memory (reference) leak in poller.register (Dave Brueck)
...
Replace some tortuous code that was trying to be clever but forgot to
DECREF the key and value, by more longwinded but obviously correct
code.
(Inspired by but not copying the fix from SF patch #475033.)
2001-10-25 20:18:35 +00:00
Guido van Rossum
e2ae77b8b8
SF patch #474590 -- RISC OS support
2001-10-24 20:42:55 +00:00
Tim Peters
4b046c252e
Stop adding 3 to FD_SETSIZE -- it makes no sense. If it turns out it
...
actually does <wink>, perhaps an Insure run will catch it.
Also removed senseless Windows comment.
2001-08-16 21:59:46 +00:00
Barry Warsaw
2f7045576d
Fixed a couple of minor formatting nits where lines were > 79 columns wide.
2001-08-16 16:55:10 +00:00
Barry Warsaw
b44740f741
select_select(): Closing bug #448351 the easy way, i.e. by changing
...
the "#ifdef MS_WINDOWS" to "#ifdef SELECT_USES_HEAP" and by
setting SELECT_USES_HEAP when FD_SETSIZE > 1024.
The indirection seems useful since this subtly changes the path
that "normal" Windows programs take (where Timmie sez FD_SETSIZE =
512). If that's a problem for Windows, he has only one place to
change.
2001-08-16 16:52:59 +00:00
Fred Drake
dff3a37afd
Make more warnings go away on the SGI compiler.
...
This is part of SF patch #424992 .
2001-07-19 21:29:49 +00:00
Andrew M. Kuchling
737fbb340e
[Bug #438050 ]
...
Include sys/poll.h if it was found by the configure script. The OpenGroup
spec says poll.h is the correct header file to use, so that file is
preferred.
2001-07-14 20:54:37 +00:00
Fred Drake
7b87f85c78
Add :method info to the PyArg_ParseTuple() format strings for poll objects.
2001-05-21 03:29:05 +00:00
Guido van Rossum
1ca8bb374e
RISCOS changes by dschwertberger
2001-03-02 06:28:17 +00:00
Tim Peters
d92dfe0ef5
SF bug 110843: Low FD_SETSIZE limit on Win32 (PR#41). Boosted to 512.
2000-12-12 01:18:41 +00:00
Andrew M. Kuchling
36d97ebd58
Add #ifdef's for platforms that don't have the constants POLLRDNORM and
...
friends. (Modified version of patch #101682 from Neil Schemenauer)
2000-09-28 21:33:44 +00:00
Fred Drake
d5fadf75e4
Rationalize use of limits.h, moving the inclusion to Python.h.
...
Add definitions of INT_MAX and LONG_MAX to pyport.h.
Remove includes of limits.h and conditional definitions of INT_MAX
and LONG_MAX elsewhere.
This closes SourceForge patch #101659 and bug #115323 .
2000-09-26 05:46:01 +00:00
Guido van Rossum
8586991099
REMOVED all CWI, CNRI and BeOpen copyright markings.
...
This should match the situation in the 1.6b1 tree.
2000-09-01 23:29:29 +00:00
Fred Drake
8ce159aef5
Peter Schneider-Kamp <nowonder@nowonder.de>:
...
Remove some of GCC's warning in -Wstrict-prototypes mode.
This closes SourceForge patch #101342 .
2000-08-31 05:18:54 +00:00