Skip to content

Commit

Permalink
change flags of getbuffer to support readonly source buffer
Browse files Browse the repository at this point in the history
  • Loading branch information
hongzhen1 committed Mar 22, 2018
1 parent d2079d3 commit c3cc805
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/ideep4py/py/swig_utils/pep_3118.i
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
}

%typemap(in) (VIEW) (int res, Py_buffer view
, int flags = PyBUF_C_CONTIGUOUS | PyBUF_RECORDS) {
, int flags = PyBUF_C_CONTIGUOUS | PyBUF_RECORDS_RO) {
/* view = new Py_buffer;*/
res = PyObject_GetBuffer($input, &view, flags);
if (res != 0) {
Expand Down

0 comments on commit c3cc805

Please sign in to comment.