Commit Graph

2106 Commits

Author SHA1 Message Date
Andrew MacIntyre
1fe0665fb6 Complete backport of rev 50787 that was started in rev 50788 2006-07-23 14:29:02 +00:00
Andrew MacIntyre
5596679a4a bugfix: PyThread_start_new_thread() returns the thread ID, not a flag;
backport of rev 50787.
2006-07-23 13:01:03 +00:00
Georg Brandl
8532999ccf Argh. "integer" is a very confusing word ;)
Actually, checking for INT_MAX and INT_MIN is correct since
the format code explicitly handles a C "int".
 (backport from rev. 46746)
2006-06-08 13:31:14 +00:00
Georg Brandl
78fbb2a032 Bug #1502750: Fix getargs "i" format to use LONG_MIN and LONG_MAX for bounds checking.
(backport from rev. 46741)
2006-06-08 12:45:05 +00:00
Brett Cannon
89d862360c Fix possible buffer overflow on Windows when reading code page.
Backport of fix for bug #1501223.
2006-06-05 23:56:36 +00:00
Thomas Wouters
eba52802cd Backport trunk's r45715:
Define MAXPATHLEN to be at least PATH_MAX, if that's defined. Python uses
MAXPATHLEN-sized buffers for various output-buffers (like to realpath()),
and that's correct on BSD platforms, but not Linux (which uses PATH_MAX, and
does not define MAXPATHLEN.) Cursory googling suggests Linux is following a
newer standard than BSD, but in cases like this, who knows. Using the
greater of PATH_MAX and 1024 as a fallback for MAXPATHLEN seems to be the
most portable solution.
2006-04-25 15:33:48 +00:00
Armin Rigo
337c143b4a Ignore the references to the dummy objects used as deleted keys
in dicts and sets when computing the total number of references.
2006-04-12 17:06:58 +00:00
Martin v. Löwis
adbd28f7b8 Backport of compile.c part of r41531 (neal.norwitz, 2005-11-24):
Fix a ref leak.
2006-03-27 21:47:54 +00:00
Anthony Baxter
022a55c0d9 update - still some old .cvsignore files lying around 2006-03-23 02:26:07 +00:00
Martin v. Löwis
73c8c2c3dd Change SystemError into SyntaxError, when a Unicode string
containing an encoding declaration is compile()d. Fixes
#1115379.
2006-03-22 13:55:50 +00:00
Hye-Shik Chang
361cd4bd6c Backport r42894: SF #1444030 Fix several potential defects found
by Coverity.
2006-03-07 15:59:09 +00:00
Martin v. Löwis
518f2a5184 Backport of memory leak fixes. 2006-03-01 21:36:32 +00:00
Brett Cannon
68e4cbbcb6 Return value off PyErr_Warn() for raising string exceptions was not being
checked.  Problem when 'warnings' was set to "error" and thus would re-raise a
new exception.
2006-02-27 23:15:56 +00:00
Tim Peters
9e777e5c6a do_mkvalue(): Squash compiler warnings about mixing
signed and unsigned types in comparison.
2006-02-27 17:49:41 +00:00
Tim Peters
91e742fb6b Merge rev 42607 from the trunk.
Patch 1413181, by Gabriel Becedillas.

PyThreadState_Delete():  if the auto-GIL-state machinery knows about
the thread state, forget it (since the thread state is being deleted,
continuing to remember it can't help, but can hurt if another thread
happens to get created with the same thread id).
2006-02-27 17:47:02 +00:00
Georg Brandl
394e4af6d5 Bug #801349: document that start/stop/step slice arguments can be None 2006-02-19 00:12:46 +00:00
Brett Cannon
df7d40861f Cast assignments to `unsigned char *` from PyString_AS_STRING() calls to
silence compiler warnings on gcc 4.0.1 .
2006-02-16 07:01:45 +00:00
Georg Brandl
2fec8b935f Update general copyright year to 2006. 2006-02-11 15:30:59 +00:00
Georg Brandl
b9c3283cc0 bug #1281408: make Py_BuildValue work with unsigned longs and long longs 2005-11-24 15:38:54 +00:00
Neal Norwitz
9aab3f04a8 Backport one of the ref/memory leaks 2005-11-21 00:05:58 +00:00
Neal Norwitz
757dab9df7 Backport:
SF Bug #1350188, "setdlopenflags" leads to crash upon "import"
 It was possible dlerror() returns a NULL pointer, use a default error
 message in this case.
2005-11-09 07:02:40 +00:00
Neal Norwitz
ecea121754 Backport: SF bug #1167751: fix incorrect code being for generator expressions. 2005-10-23 00:44:03 +00:00
Neal Norwitz
2d0d6c9b82 Backport:
Fix SF bug #976608, Unhelpful error message when mtime of a module is -1
2005-10-03 04:50:55 +00:00
Neal Norwitz
c2b7c59267 Backport:
SF bug #887946, segfault if redirecting directory
Also provide a warning if a directory is passed on the command line.
Add minimal command line test.
2005-10-03 01:03:46 +00:00
Neal Norwitz
d00e54bc25 Backported:
Fix segfault with invalid coding.
(See SF bug: 772896 for another fix)
2005-10-02 01:51:56 +00:00