/external/autotest/client/site_tests/platform_ToolchainTests/src/ |
D | clang-fortify-tests.cpp | 118 char small_buffer[8] = {}; in TestString() local 121 char large_buffer[sizeof(small_buffer) + 1] = {}; in TestString() 123 EXPECT_DEATH(memcpy(small_buffer, large_buffer, sizeof(large_buffer))); in TestString() 125 EXPECT_DEATH(memmove(small_buffer, large_buffer, sizeof(large_buffer))); in TestString() 127 EXPECT_DEATH(mempcpy(small_buffer, large_buffer, sizeof(large_buffer))); in TestString() 129 EXPECT_DEATH(memset(small_buffer, 0, sizeof(large_buffer))); in TestString() 131 memset(small_buffer, sizeof(small_buffer), 0); in TestString() 133 EXPECT_DEATH(bcopy(large_buffer, small_buffer, sizeof(large_buffer))); in TestString() 135 EXPECT_DEATH(bzero(small_buffer, sizeof(large_buffer))); in TestString() 140 _Static_assert(sizeof(large_string) > sizeof(small_buffer), ""); in TestString() [all …]
|
/external/python/cpython2/Objects/ |
D | bytesobject.c | 3170 memset(writer, 0, offsetof(_PyBytesWriter, small_buffer)); in _PyBytesWriter_Init() 3172 memset(writer->small_buffer, 0xCB, sizeof(writer->small_buffer)); in _PyBytesWriter_Init() 3187 return writer->small_buffer; in _PyBytesWriter_AsString() 3294 writer->small_buffer, in _PyBytesWriter_Resize() 3300 memset(writer->small_buffer, 0xDB, sizeof(writer->small_buffer)); in _PyBytesWriter_Resize() 3353 writer->allocated = sizeof(writer->small_buffer) - 1; in _PyBytesWriter_Alloc() 3367 writer->small_buffer[writer->allocated] = 0; in _PyBytesWriter_Alloc() 3369 writer->allocated = sizeof(writer->small_buffer); in _PyBytesWriter_Alloc() 3371 return _PyBytesWriter_Prepare(writer, writer->small_buffer, size); in _PyBytesWriter_Alloc() 3390 result = PyByteArray_FromStringAndSize(writer->small_buffer, size); in _PyBytesWriter_Finish() [all …]
|
D | fileobject.c | 1686 char small_buffer[SMALLCHUNK]; in file_readlines() local 1687 char *buffer = small_buffer; in file_readlines() 1755 memcpy(buffer, small_buffer, nfilled); in file_readlines()
|
/external/python/cpython3/Objects/ |
D | bytesobject.c | 3233 memset(writer, 0, offsetof(_PyBytesWriter, small_buffer)); in _PyBytesWriter_Init() 3235 memset(writer->small_buffer, PYMEM_CLEANBYTE, in _PyBytesWriter_Init() 3236 sizeof(writer->small_buffer)); in _PyBytesWriter_Init() 3251 return writer->small_buffer; in _PyBytesWriter_AsString() 3359 writer->small_buffer, in _PyBytesWriter_Resize() 3365 memset(writer->small_buffer, PYMEM_CLEANBYTE, in _PyBytesWriter_Resize() 3366 sizeof(writer->small_buffer)); in _PyBytesWriter_Resize() 3419 writer->allocated = sizeof(writer->small_buffer) - 1; in _PyBytesWriter_Alloc() 3433 writer->small_buffer[writer->allocated] = 0; in _PyBytesWriter_Alloc() 3435 writer->allocated = sizeof(writer->small_buffer); in _PyBytesWriter_Alloc() [all …]
|
D | unicodeobject.c | 5502 const char *start = writer.use_small_buffer ? writer.small_buffer : in unicode_fill_utf8()
|
/external/python/cpython3/Include/cpython/ |
D | bytesobject.h | 64 char small_buffer[512]; member
|
/external/python/cpython2/Modules/ |
D | bz2module.c | 652 char small_buffer[SMALLCHUNK]; in BZ2File_readlines() local 653 char *buffer = small_buffer; in BZ2File_readlines() 731 memcpy(buffer, small_buffer, nfilled); in BZ2File_readlines() 1017 char small_buffer[SMALLCHUNK]; in BZ2File_seek() local 1018 char *buffer = small_buffer; in BZ2File_seek()
|
/external/pdfium/fpdfsdk/ |
D | fpdf_text_embeddertest.cpp | 85 unsigned short small_buffer[12]; in TEST_F() local 87 EXPECT_EQ(6, FPDFText_GetText(textpage, 0, 5, small_buffer)); in TEST_F() 88 EXPECT_TRUE(check_unsigned_shorts(kSmallExpected, small_buffer, in TEST_F()
|
/external/libchrome/base/files/ |
D | file_util_unittest.cc | 2742 std::vector<char> small_buffer(kTestData.size() / 2); in TEST_F() local 2748 file_path, &small_buffer[0], static_cast<int>(small_buffer.size())); in TEST_F() 2749 EXPECT_EQ(static_cast<int>(small_buffer.size()), bytes_read_small); in TEST_F() 2751 std::string(kTestData.begin(), kTestData.begin() + small_buffer.size()), in TEST_F() 2752 std::string(small_buffer.begin(), small_buffer.end())); in TEST_F()
|