##// END OF EJS Templates
pathencode: skip encoding if input is already longer than maxstorepathlen...
Adrian Buehlmann -
r17692:fb458b3e default
parent child Browse files
Show More
@@ -501,6 +501,12 b' PyObject *pathencode(PyObject *self, PyO'
501 return NULL;
501 return NULL;
502 }
502 }
503
503
504 if (len > maxstorepathlen) {
505 newobj = Py_None;
506 Py_INCREF(newobj);
507 return newobj;
508 }
509
504 newlen = len ? basicencode(NULL, 0, path, len + 1) : 1;
510 newlen = len ? basicencode(NULL, 0, path, len + 1) : 1;
505
511
506 if (newlen <= maxstorepathlen + 1) {
512 if (newlen <= maxstorepathlen + 1) {
General Comments 0
You need to be logged in to leave comments. Login now