##// END OF EJS Templates
parsers: set exception when there's too little string data to extract parents...
Augie Fackler -
r26052:b970418b default
parent child Browse files
Show More
@@ -481,8 +481,11 b' static PyObject *parse_dirstate(PyObject'
481 len = readlen;
481 len = readlen;
482
482
483 /* read parents */
483 /* read parents */
484 if (len < 40)
484 if (len < 40) {
485 PyErr_SetString(
486 PyExc_ValueError, "too little data for parents");
485 goto quit;
487 goto quit;
488 }
486
489
487 parents = Py_BuildValue("s#s#", str, 20, str + 20, 20);
490 parents = Py_BuildValue("s#s#", str, 20, str + 20, 20);
488 if (!parents)
491 if (!parents)
General Comments 0
You need to be logged in to leave comments. Login now