| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
| |
|
|
|
|
| |
Probably should be backported.
|
|
|
|
| |
Most of these can be backported.
|
| |
|
|
|
|
|
|
| |
for Py_Main().
Thanks to Kalle Svensson and Skip Montanaro for the patches.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
don't understand how this function works, also beefed up the docs. The
most common usage error is of this form (often spread out across gotos):
if (_PyString_Resize(&s, n) < 0) {
Py_DECREF(s);
s = NULL;
goto outtahere;
}
The error is that if _PyString_Resize runs out of memory, it automatically
decrefs the input string object s (which also deallocates it, since its
refcount must be 1 upon entry), and sets s to NULL. So if the "if"
branch ever triggers, it's an error to call Py_DECREF(s): s is already
NULL! A correct way to write the above is the simpler (and intended)
if (_PyString_Resize(&s, n) < 0)
goto outtahere;
Bugfix candidate.
|
|
|
|
|
| |
PyArg_Parse( "s" ) -> PyString_AsString
PyArg_Parse( "t#" ) -> PyString_AsStringAndSize
|
|
|
|
| |
directly.
|
|
|
|
| |
Can go into 2.2.x, but not necessary.
|
| |
|
|
|
|
|
| |
Also changed <>-style #includes to ""-style in some places where the
former didn't make sense.
|
|
|
|
|
|
|
|
|
| |
*are* obsolete; three variables and the maketrans() function are not
(yet) obsolete.
Add a compensating warnings.filterwarnings() call to test_strop.py.
Add this to the NEWS.
|
|
|
|
|
|
|
| |
meaning infinity -- but at least warn about it in the code! I pissed
away a couple hours on this today, and don't wish the same on the next
in line.
Bugfix candidate.
|
|
|
|
|
|
|
| |
means "replace everything". But the string module, string.replace()
amd test_string.py believe a 0 count means "replace nothing".
"Nothing" wins, strop loses.
Bugfix candidate.
|
|
|
|
|
|
| |
out of synch than I realized, and I managed to break replace's "count"
argument when it was 0. All is well again. Maybe.
Bugfix candidate.
|
|
|
|
|
|
| |
mymemXXX stuff, and they were already out of synch. Fix the remaining
bugs in both and get them back in synch.
Bugfix release candidate.
|
|
|
|
|
|
| |
Platform blew up on "123".replace("123", ""). Michael Hudson pinned the
blame on platform malloc(0) returning NULL.
This is a candidate for all bugfix releases.
|
| |
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
| |
This should match the situation in the 1.6b1 tree.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Py_FatalError() from module initialization functions. The importing
mechanism already checks for PyErr_Occurred() after module importation
and it Does The Right Thing.
Unfortunately, the following either were not compiled or tested by the
regression suite, due to issues with my development platform:
almodule.c
cdmodule.c
mpzmodule.c
puremodule.c
timingmodule.c
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
and a couple of functions that were missed in the previous batches. Not
terribly tested, but very carefully scrutinized, three times.
All these were found by the little findkrc.py that I posted to python-dev,
which means there might be more lurking. Cases such as this:
long
func(a, b)
long a;
long b; /* flagword */
{
and other cases where the last ; in the argument list isn't followed by a
newline and an opening curly bracket. Regexps to catch all are welcome, of
course ;)
|
|
|
|
|
|
|
|
|
|
| |
comments, docstrings or error messages. I fixed two minor things in
test_winreg.py ("didn't" -> "Didn't" and "Didnt" -> "Didn't").
There is a minor style issue involved: Guido seems to have preferred English
grammar (behaviour, honour) in a couple places. This patch changes that to
American, which is the more prominent style in the source. I prefer English
myself, so if English is preferred, I'd be happy to supply a patch myself ;)
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
For more comments, read the patches@python.org archives.
For documentation read the comments in mymalloc.h and objimpl.h.
(This is not exactly what Vladimir posted to the patches list; I've
made a few changes, and Vladimir sent me a fix in private email for a
problem that only occurs in debug mode. I'm also holding back on his
change to main.c, which seems unnecessary to me.)
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Attached you find an update of the Unicode implementation.
The patch is against the current CVS version. I would appreciate
if someone with CVS checkin permissions could check the changes
in.
The patch contains all bugs and patches sent this week and also
fixes a leak in the codecs code and a bug in the free list code
for Unicode objects (which only shows up when compiling Python
with Py_DEBUG; thanks to MarkH for spotting this one).
|
|
|
|
| |
PyArg_ParseTuple() format string arguments as possible.
|
|
|
|
|
| |
parameter match. Error pointed out by François
Pinard <pinard@iro.umontreal.ca> on c.l.py.
|
|
|
|
|
|
| |
converted was a "digit" -- use isalnum(). This test is there only to
guard against "+" or "-" being interpreted as a valid int literal.
Reported by Takahiro Nakayama.
|
|
|
|
| |
the SunPro C compiler to choke. Removed this redundant line.
|
|
|
|
|
| |
I've reformatted it, added a few comments, a test for tabsize <= 0,
and used the AS_STRING macro.
|
| |
|
|
|
|
| |
on BeOS or Windows.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
previous version of this code would not show the offending input, even
though there was code that attempted this.)
|
| |
|
|
|
|
|
| |
tp_as_sequence or tp_as_mapping structure is made without checking it
for NULL first.
|
| |
|