Cleanup: use size_t for BLF text API functions
Also minor cleanup to txt_sel_to_buf: - Use memcpy instead of strncpy as the strings don't contain nil bytes. - Replace while loops with for loops.
This commit is contained in:
@@ -102,7 +102,7 @@ static bool python_script_exec(
|
||||
|
||||
fn_dummy_py = PyC_UnicodeFromByte(fn_dummy);
|
||||
|
||||
int buf_len_dummy;
|
||||
size_t buf_len_dummy;
|
||||
buf = txt_to_buf(text, &buf_len_dummy);
|
||||
text->compiled = Py_CompileStringObject(buf, fn_dummy_py, Py_file_input, NULL, -1);
|
||||
MEM_freeN(buf);
|
||||
|
||||
Reference in New Issue
Block a user