summaryrefslogtreecommitdiffstats
path: root/Python/codecs.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix a few more ref leaks. Backport candidateNeal Norwitz2005-11-241-3/+3
|
* Fix a couple of signed/unsigned comparison warningsNeal Norwitz2004-07-081-1/+1
|
* Changed random calls to PyThreadState_Get() to use the macroNicholas Bastin2004-03-241-5/+5
|
* Fix gcc 3.3 warnings related to Py_UNICODE_WIDE.Hye-Shik Chang2003-12-291-2/+20
|
* Fixed SF bug #663074. The codec system was using global staticGustavo Niemeyer2003-03-191-84/+65
| | | | | | | | | variables to store internal data. As a result, any atempts to use the unicode system with multiple active interpreters, or successive interpreter executions, would fail. Now that information is stored into members of the PyInterpreterState structure.
* Patch for bug reported in patch #686627: import race condition inMarc-André Lemburg2003-02-141-1/+1
| | | | codecs registry startup.
* Properly compute array size even for --disable-unicode.Martin v. Löwis2002-11-211-1/+1
|
* Fix PEP 293 related problems with --disable-unicode buildsWalter Dörwald2002-11-211-0/+6
| | | | | reported by Michael Hudson in http://mail.python.org/pipermail/python-dev/2002-November/030299.html
* Add encoding name in LookupError. Fixes #615013. Will backport to 2.2.Martin v. Löwis2002-09-261-2/+2
|
* Check string for NULL before using it to format the error message.Walter Dörwald2002-09-021-3/+6
| | | | (Spotted by Neal Norwitz)
* PEP 293 implemention (from SF patch http://www.python.org/sf/432401)Walter Dörwald2002-09-021-0/+399
|
* Fix bug [ 549731 ] Unicode encoders appears to leak references.Mark Hammond2002-07-181-4/+10
| | | | Python 2.2.1 bugfix candidate.
* Rationalize use of limits.h, moving the inclusion to Python.h.Fred Drake2000-09-261-3/+0
| | | | | | | | 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.
* Changing the CNRI copyright notice according to CNRI's instructions.Guido van Rossum2000-08-031-1/+1
| | | | | This is a notice without a date, which apparently is not a claim to copyright but only advice to the reader. IANAL. :-)
* Mass ANSIfication of function definitions. Doesn't cover all 'extern'Thomas Wouters2000-07-221-3/+3
| | | | declarations yet, those come later.
* Spelling fixes supplied by Rob W. W. Hooft. All these are fixes in eitherThomas Wouters2000-07-161-2/+2
| | | | | | | | | | 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 ;)
* Include limits.h if we have it.Jack Jansen2000-07-031-0/+3
|
* Change the loop index in normalizestring() to size_t too, to avoid aGuido van Rossum2000-06-291-1/+1
| | | | warning on Windows.
* Trent Mick's Win64 changes: size_t vs. int or long; also some overflowGuido van Rossum2000-06-281-2/+7
| | | | tests.
* M.-A. Lemburg <mal@lemburg.com>:Fred Drake2000-05-091-9/+5
| | | | | | | Moved some docs to the include file. Added a NULL check to _PyCodec_Lookup() to make it core dump safe.
* Marc-Andre's third try at this bulk patch seems to work (except thatGuido van Rossum2000-04-051-5/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | his copy of test_contains.py seems to be broken -- the lines he deleted were already absent). Checkin messages: New Unicode support for int(), float(), complex() and long(). - new APIs PyInt_FromUnicode() and PyLong_FromUnicode() - added support for Unicode to PyFloat_FromString() - new encoding API PyUnicode_EncodeDecimal() which converts Unicode to a decimal char* string (used in the above new APIs) - shortcuts for calls like int(<int object>) and float(<float obj>) - tests for all of the above Unicode compares and contains checks: - comparing Unicode and non-string types now works; TypeErrors are masked, all other errors such as ValueError during Unicode coercion are passed through (note that PyUnicode_Compare does not implement the masking -- PyObject_Compare does this) - contains now works for non-string types too; TypeErrors are masked and 0 returned; all other errors are passed through Better testing support for the standard codecs. Misc minor enhancements, such as an alias dbcs for the mbcs codec. Changes: - PyLong_FromString() now applies the same error checks as does PyInt_FromString(): trailing garbage is reported as error and not longer silently ignored. The only characters which may be trailing the digits are 'L' and 'l' -- these are still silently ignored. - string.ato?() now directly interface to int(), long() and float(). The error strings are now a little different, but the type still remains the same. These functions are now ready to get declared obsolete ;-) - PyNumber_Int() now also does a check for embedded NULL chars in the input string; PyNumber_Long() already did this (and still does) Followed by: Looks like I've gone a step too far there... (and test_contains.py seem to have a bug too). I've changed back to reporting all errors in PyUnicode_Contains() and added a few more test cases to test_contains.py (plus corrected the join() NameError).
* Marc-Andre Lemburg: Error reporting in the codec registry and lookupGuido van Rossum2000-03-311-12/+46
| | | | mechanism is enhanced to be more informative.
* Marc-Andre Lemburg:Guido van Rossum2000-03-241-8/+6
| | | | | | Andy Robinson noted a core dump in the codecs.c file. This was introduced by my latest patch which fixed a memory leak in codecs.c. The bug causes all successful codec lookups to fail.
* On 17-Mar-2000, Marc-Andre Lemburg said:Barry Warsaw2000-03-201-2/+12
| | | | | | | | | | | | | 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).
* Python Codec Registry and support functions, written by Marc-AndreGuido van Rossum2000-03-101-0/+382
Lemburg.