Skip to content

Commit

Permalink
Handle module returns smaller than he requested size.
Browse files Browse the repository at this point in the history
  • Loading branch information
philip-davis committed Nov 13, 2023
1 parent 40b40f6 commit 820e3a9
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/dspaces-server.c
Original file line number Diff line number Diff line change
Expand Up @@ -1858,7 +1858,6 @@ static struct dspaces_module_ret *py_res_buf(PyObject *pResult)
ret->tag = PyArray_TYPE(pArray);
ret->elem_size = PyArray_ITEMSIZE(pArray);
data_len = ret->len * ret->elem_size;
fprintf(stderr, "%s: data_len = %zi\n", __func__, data_len);
ret->data = malloc(data_len);
memcpy(ret->data, PyArray_DATA(pArray), data_len);

Expand Down

0 comments on commit 820e3a9

Please sign in to comment.