1699 Commits

Author SHA1 Message Date
Andrew M. Kuchling
885fe06353 Add extra SHA tests 2006-11-20 13:31:53 +00:00
Samuele Pedroni
20cf51cc64 adding passing test. testing for g(*Nothing()) where Nothing is a user-defined iterator. 2004-02-21 20:58:04 +00:00
Anthony Baxter
0a8f2996a5 Backport of rhettinger's funcobject.c 2.63, bugfix for SF bug 753451
Check the argument of classmethod is callable. (prevents
classmethod(classmethod(func)) from bombing out.
2003-07-13 13:54:34 +00:00
Skip Montanaro
d8fcbddc8d backport -uall,-resource stuff
add sunos5 and hpux11 expected skips
2003-06-21 16:13:49 +00:00
Skip Montanaro
8ebdd33ebf check getservbyname with several protocols, not just telnet 2003-06-21 15:59:13 +00:00
Neal Norwitz
b1ccf7f137 Backport 1.194:
Add test for bug #751998.
2003-06-16 23:38:27 +00:00
Martin v. Löwis
d2cd3ef91f Patch #746801: FreeBSD 4 expected failures, by Charles Swiger. 2003-06-07 20:02:27 +00:00
Barry Warsaw
be1eb0c8f4 crash_in_get_sf736892(): A test of SF 736892, forcing function to act
like an unbound method dumps core.
2003-05-29 15:14:52 +00:00
Guido van Rossum
10b1cd9d80 Remove debug code from weakref_segfault().
Also move the call of the test to the top; the crash is caused by a
double free.
2003-05-29 14:31:42 +00:00
Guido van Rossum
189a6c94e4 Add testcase for SF 742911. 2003-05-29 14:21:29 +00:00
Barry Warsaw
39a8fddb15 The backport gets Fred's seal of approval:
SF 742860: WeakKeyDictionary __delitem__ uses iterkeys

    Someone review this, please!  Final releases are getting close, Fred
    (the weakref guy) won't be around until Tuesday, and the pre-patch
    code can indeed raise spurious RuntimeErrors in the presence of
    threads or mutating comparison functions.

    See the bug report for my confusions:  I can't see any reason for why
    __delitem__ iterated over the keys.  The new one-liner implementation
    is much faster, can't raise RuntimeError, and should be better-behaved
    in all respects wrt threads.

    New tests test_weak_keyed_bad_delitem and
    test_weak_keyed_cascading_deletes fail before this patch.

Backported the tests and the patch.
2003-05-28 23:03:30 +00:00
Jeremy Hylton
826f68b25b Backport fix for SF bug 692776.
Add a tp_new slot to function objects that handles the case of a
function requiring a closure.  Put the function type in the new
module, rather than having a function new.function().  Add tests.
2003-05-22 18:11:20 +00:00
Jeremy Hylton
6c75479a80 Backport fix for SF bug 734869 and sundry compiler cleanups. 2003-05-22 16:43:04 +00:00
Samuele Pedroni
0ea0a18669 minor fix, jython-only. Don't asssume stdout to save is the ur-stdout. 2003-05-17 12:50:33 +00:00
Samuele Pedroni
e163df1bce beefed up version: jython support, covers now fixed differences between CPython/Jython. 2003-05-17 02:35:37 +00:00
Tim Peters
fa90c3e468 file_truncate(): Backported 2.3 code so that file.truncate(n) works on
Windows when n is too big to fit in a 32-bit int.  This was a hole in
2.2's large file support on Windows, and turns out it's a bad hole at
least for ZODB.
2003-04-30 19:24:59 +00:00
Martin v. Löwis
2c29daeb11 Patch #681152: Support escaped unicode characters in classes. Fixes 612074. 2003-04-19 08:39:04 +00:00
Tim Peters
8998a81937 Fixed the gc-vs-__del__ bugs for new-style classes. That's it for this one. 2003-04-08 20:33:05 +00:00
Tim Peters
1ac384995c Backporting new gc-vs-__del__ tests. These pass, but are restricted
to old-style classes.  New-style classes remain vulnerable in 2.2.
2003-04-08 19:32:53 +00:00
Tim Peters
44198f0465 This was failing on Windows, due to various attempts to delete files
that were still open.  Made the tail end of the test look more like
the CVS head version.
2003-03-31 22:48:29 +00:00
Skip Montanaro
18711bce89 backport test skip for test_locale on Mac OS X 2003-03-31 22:11:45 +00:00
Skip Montanaro
ddf625bd89 backport largefile resource requirement for Mac OSX 2003-03-31 17:42:52 +00:00
Tim Peters
58d23ae9a9 SF bug 705836: struct.pack of floats in non-native endian order
pack_float, pack_double, save_float:  All the routines for creating
IEEE-format packed representations of floats and doubles simply ignored
that rounding can (in rare cases) propagate out of a long string of
1 bits.  At worst, the end-off carry can (by mistake) interfere with
the exponent value, and then unpacking yields a result wrong by a factor
of 2.  In less severe cases, it can end up losing more low-order bits
than intended, or fail to catch overflow *caused* by rounding.
2003-03-20 18:31:20 +00:00
Thomas Wouters
c5f77780f0 binascii_a2b_base64: Properly return an empty string if the input was all
invalid, rather than returning a string of random garbage of the
    estimated result length. Closes SF patch #703471 by Hye-Shik Chang.

Backport from 2.3.
2003-03-17 11:34:43 +00:00
Guido van Rossum
3046177b09 Backport:
Fix from SF patch #633359 by Greg Chapman for SF bug #610299:
    The problem is in sre_compile.py: the call to
    _compile_charset near the end of _compile_info forgets to
    pass in the flags, so that the info charset is not compiled
    with re.U. (The info charset is used when searching to find
    the first character at which a match could start; it is not
    generated for patterns beginning with a repeat like '\w{1}'.)
2003-02-24 01:23:03 +00:00