fixes for stuff_string() bounds checking

This commit is contained in:
taylor committed 2006-09-11 01:17:07 +00:00
1 parent 2f3b5f2910
commit 6ab6cd71ce
38 files changed
+454 -317

No files matched your search

+3 -3
View File
@@ -648,8 +648,8 @@ PyBytecode python_parse()
sprintf(debug_str, "parse_python(ln) %d", Total_lines_parsed++);
//Stuff it
char buf[PARSE_BUF_SIZE] = {0};
stuff_string(buf, F_RAW, NULL, sizeof(buf)-1);
char buf[PARSE_BUF_SIZE];
stuff_string(buf, F_RAW, sizeof(buf));
//Compile & return it
return PyBytecode(Py_CompileString(buf, debug_str, Py_eval_input));
@@ -683,4 +683,4 @@ PyResult py_session_evaluate(PySession* session, PyBytecode* code)
return PyResult(NULL);
}
#endif
#endif