mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-11 19:19:35 +02:00
Fix warning on ancient gcc
This commit is contained in:
@@ -49,7 +49,7 @@ iter_job(PyObject *self UNUSED, PyObject *args) {
|
||||
if (!PyArg_ParseTuple(args, "O!y#|p", &PyCapsule_Type, &job_capsule, &input_data, &input_data_size, &eof)) return NULL;
|
||||
GET_JOB_FROM_CAPSULE;
|
||||
if (eof == -1) eof = input_data_size > 0 ? 0 : 1;
|
||||
rs_buffers_t buffer = {.avail_in=input_data_size, .next_in = input_data, .eof_in=eof, .avail_out=MAX(IO_BUFFER_SIZE, 2 * input_data_size)};
|
||||
rs_buffers_t buffer = {.avail_in=input_data_size, .next_in = input_data, .eof_in=eof, .avail_out=MAX(IO_BUFFER_SIZE, 2 * (size_t)input_data_size)};
|
||||
PyObject *ans = PyBytes_FromStringAndSize(NULL, buffer.avail_out);
|
||||
if (!ans) return NULL;
|
||||
buffer.next_out = PyBytes_AS_STRING(ans);
|
||||
|
||||
Reference in New Issue
Block a user