##// END OF EJS Templates
pathencode: improve error messages slightly...
Augie Fackler -
r38067:9aaa74f9 default
parent child Browse files
Show More
@@ -664,7 +664,8 b' static int sha1hash(char hash[20], const'
664 Py_DECREF(name);
664 Py_DECREF(name);
665
665
666 if (hashlib == NULL) {
666 if (hashlib == NULL) {
667 PyErr_SetString(PyExc_ImportError, "hashlib");
667 PyErr_SetString(PyExc_ImportError,
668 "pathencode failed to find hashlib");
668 return -1;
669 return -1;
669 }
670 }
670 shafunc = PyObject_GetAttrString(hashlib, "sha1");
671 shafunc = PyObject_GetAttrString(hashlib, "sha1");
@@ -673,7 +674,7 b' static int sha1hash(char hash[20], const'
673 if (shafunc == NULL) {
674 if (shafunc == NULL) {
674 PyErr_SetString(PyExc_AttributeError,
675 PyErr_SetString(PyExc_AttributeError,
675 "module 'hashlib' has no "
676 "module 'hashlib' has no "
676 "attribute 'sha1'");
677 "attribute 'sha1' in pathencode");
677 return -1;
678 return -1;
678 }
679 }
679 }
680 }
General Comments 0
You need to be logged in to leave comments. Login now