Lines Matching refs:alloc
129 size_t alloc = PyBytes_GET_SIZE(self->buf);
138 if (size < alloc / 2) {
140 alloc = size + 1;
142 else if (size < alloc) {
146 else if (size <= alloc * 1.125) {
148 alloc = size + (size >> 3) + (size < 9 ? 3 : 6);
152 alloc = size + 1;
155 if (alloc > ((size_t)-1) / sizeof(char))
159 if (unshare_buffer(self, alloc) < 0)
163 if (_PyBytes_Resize(&self->buf, alloc) < 0)