Serhiy Storchaka
7b6e3b91f5
Issue #24467 : Fixed possible buffer over-read in bytearray. The bytearray
...
object now always allocates place for trailing null byte and it's buffer now
is always null-terminated.
2015-06-29 21:14:06 +03:00
Serhiy Storchaka
fa494fd883
Issue #24115 : Update uses of PyObject_IsTrue(), PyObject_Not(),
...
PyObject_IsInstance(), PyObject_RichCompareBool() and _PyDict_Contains()
to check for and handle errors correctly.
2015-05-30 17:45:22 +03:00
Antoine Pitrou
2545411e28
Issue #23985 : Fix a possible buffer overrun when deleting a slice from the front of a bytearray and then appending some other bytes data.
...
Patch by Martin Panter.
2015-05-19 20:52:27 +02:00
Serhiy Storchaka
4fdb68491e
Issue #22896 : Avoid to use PyObject_AsCharBuffer(), PyObject_AsReadBuffer()
...
and PyObject_AsWriteBuffer().
2015-02-03 01:21:08 +02:00
Antoine Pitrou
cc23154d02
Issue #22335 : Fix crash when trying to enlarge a bytearray to 0x7fffffff bytes on a 32-bit platform.
2014-11-02 18:40:09 +01:00
Kristján Valur Jónsson
c5cc5011ac
Make the various iterators' "setstate" sliently and consistently clip the
...
index. This avoids the possibility of setting an iterator to an invalid
state.
2014-03-05 15:23:07 +00:00
Kristján Valur Jónsson
25dded041f
Make the various iterators' "setstate" sliently and consistently clip the
...
index. This avoids the possibility of setting an iterator to an invalid
state.
2014-03-05 13:47:57 +00:00
Victor Stinner
8455723cfb
Close #19568 : Fix bytearray_setslice_linear(), fix handling of
...
PyByteArray_Resize() failure: leave the bytearray object in an consistent state.
If growth < 0, handling the memory allocation failure is tricky here because
the bytearray object has already been modified. If lo != 0, the operation is
completed, but a MemoryError is still raised and the memory block is not
shrinked. If lo == 0, the bytearray is restored in its previous state and a
MemoryError is raised.
2013-11-21 12:29:51 +01:00
Ezio Melotti
745d54d2fa
#17806 : Added keyword-argument support for "tabsize" to str/bytes.expandtabs().
2013-11-16 19:10:57 +02:00
Antoine Pitrou
5b72075387
Hopefully fix Windows compilation error following 499a96611baa
2013-10-05 21:24:10 +02:00
Antoine Pitrou
5df8a8a1fd
Issue #19087 : Improve bytearray allocation in order to allow cheap popping of data at the front (slice deletion).
2013-10-05 21:12:18 +02:00
Antoine Pitrou
9ed5f27266
Issue #18722 : Remove uses of the "register" keyword in C code.
2013-08-13 20:18:52 +02:00
Christian Heimes
6895947570
Propagate error when PyByteArray_Resize() fails in bytearray_translate()
...
CID 715334
2013-07-21 02:04:44 +02:00
Christian Heimes
c731bbe665
Propagate error when PyByteArray_Resize() fails in bytearray_translate()
...
CID 715334
2013-07-21 02:04:35 +02:00
Christian Heimes
e9d08cf450
Fix compilation on Windows
2012-11-03 23:08:27 +01:00
Christian Heimes
d081fbba58
Fix compilation on Windows
2012-11-03 23:08:18 +01:00
Christian Heimes
6d26ade920
Fix compilation on Windows
2012-11-03 23:07:59 +01:00
Ezio Melotti
212843b29f
#8401 : merge with 3.3.
2012-11-03 21:24:47 +02:00
Ezio Melotti
7376801f61
#8401 : merge with 3.2.
2012-11-03 21:22:41 +02:00
Ezio Melotti
c64bcbec4b
#8401 : assigning an int to a bytearray slice (e.g. b[3:4] = 5) now raises an error.
2012-11-03 21:19:06 +02:00
Antoine Pitrou
cfc22b4a9b
Issue #15958 : bytes.join and bytearray.join now accept arbitrary buffer objects.
2012-10-16 21:07:23 +02:00
Armin Ronacher
aa9a79d279
Issue #16148 : implemented PEP 424
2012-10-06 14:03:24 +02:00
Stefan Krah
7d12d9df13
Issue #12834 : Fix PyBuffer_ToContiguous() for non-contiguous arrays.
2012-07-28 12:25:55 +02:00
Antoine Pitrou
a701388de1
Rename _PyIter_GetBuiltin to _PyObject_GetBuiltin, and do not include it in the stable ABI.
2012-04-05 00:04:20 +02:00
Kristján Valur Jónsson
31668b8f7a
Issue #14288 : Serialization support for builtin iterators.
2012-04-03 10:49:41 +00:00
Antoine Pitrou
29b964d0dd
Issue #13019 : Fix potential reference leaks in bytearray.extend().
...
Patch by Suman Saha.
2012-04-01 16:08:11 +02:00
Antoine Pitrou
58bb82e7b4
Issue #13019 : Fix potential reference leaks in bytearray.extend().
...
Patch by Suman Saha.
2012-04-01 16:05:46 +02:00
Ezio Melotti
cda6b6d60d
#14081 : The sep and maxsplit parameter to str.split, bytes.split, and bytearray.split may now be passed as keyword arguments.
2012-02-26 09:39:55 +02:00
Victor Stinner
bb2e9c477d
Issue #11231 : Fix bytes and bytearray docstrings
...
Patch written by Brice Berna.
2011-12-17 23:18:07 +01:00
Victor Stinner
e010fc029d
Issue #11231 : Fix bytes and bytearray docstrings
...
Patch written by Brice Berna.
2011-12-17 23:18:43 +01:00
Antoine Pitrou
b0e1f8b38b
Issue #13503 : Use a more efficient reduction format for bytearrays with
...
pickle protocol >= 3. The old reduction format is kept with older
protocols in order to allow unpickling under Python 2.
Patch by Irmen de Jong.
2011-12-05 20:40:08 +01:00
Antoine Pitrou
39aba4f563
Use the small object allocator for small bytearrays
2011-11-12 21:15:28 +01:00
Antoine Pitrou
ac65d96777
Issue #12170 : The count(), find(), rfind(), index() and rindex() methods
...
of bytes and bytearray objects now accept an integer between 0 and 255
as their first argument. Patch by Petri Lehtinen.
2011-10-20 23:54:17 +02:00
Martin v. Löwis
bd928fef42
Rename _Py_identifier to _Py_IDENTIFIER.
2011-10-14 10:20:37 +02:00
Victor Stinner
f5cff56a1b
Issue #13088 : Add shared Py_hexdigits constant to format a number into base 16
2011-10-14 02:13:11 +02:00
Martin v. Löwis
1ee1b6fe0d
Use identifier API for PyObject_GetAttrString.
2011-10-10 18:11:30 +02:00
Victor Stinner
6430fd56b4
Fix hex_digit_to_int() prototype: expect Py_UCS4, not Py_UNICODE
2011-09-29 04:02:13 +02:00
Martin v. Löwis
d63a3b8beb
Implement PEP 393.
2011-09-28 07:41:54 +02:00
Mark Dickinson
0d5f6adbb3
Issue #13012 : Allow 'keepends' to be passed as a keyword argument in str.splitlines, bytes.splitlines and bytearray.splitlines.
2011-09-24 09:14:39 +01:00
Brian Curtin
dfc80e3d97
Replace Py_NotImplemented returns with the macro form Py_RETURN_NOTIMPLEMENTED.
...
The macro was introduced in #12724 .
2011-08-10 20:28:54 -05:00
Senthil Kumaran
fcdaaa9011
merge from 3.2 - Fix closes Issue12621 - Fix docstrings of find and rfind methods of bytes/bytearry/unicodeobject.
2011-07-27 23:34:29 +08:00
Senthil Kumaran
53516a82df
Fix closes Issue12621 - Fix docstrings of find and rfind methods of bytes/bytearry/unicodeobject.
2011-07-27 23:33:54 +08:00
Ezio Melotti
bf1253b25a
#6780 : merge with 3.2.
2011-04-26 06:45:24 +03:00
Ezio Melotti
f2b3f780a1
#6780 : merge with 3.1.
2011-04-26 06:40:59 +03:00
Ezio Melotti
ba42fd5801
#6780 : fix starts/endswith error message to mention that tuples are accepted too.
2011-04-26 06:09:45 +03:00
Jesus Cea
c1ceb64e41
MERGE: startswith and endswith don't accept None as slice index. Patch by Torsten Becker. ( closes #11828 )
2011-04-20 17:59:29 +02:00
Jesus Cea
6159ee3cf5
MERGE: startswith and endswith don't accept None as slice index. Patch by Torsten Becker. ( closes #11828 )
2011-04-20 17:42:50 +02:00
Jesus Cea
ac4515063c
startswith and endswith don't accept None as slice index. Patch by Torsten Becker. ( closes #11828 )
2011-04-20 17:09:23 +02:00
Ezio Melotti
4969f709cc
#11515 : Merge with 3.1.
2011-03-15 05:59:46 +02:00
Ezio Melotti
42da663e6f
#11515 : fix several typos. Patch by Piotr Kasprzyk.
2011-03-15 05:18:48 +02:00