Commit e894e93f authored by Brett Cannon's avatar Brett Cannon

Remove a redundant string length check and variable assignment.

Found with Clang's static analyzer.
parent 79832844
......@@ -903,7 +903,6 @@ whichmodule(PyObject *global, PyObject *global_name)
like this rule. jlf
*/
if (!j) {
j=1;
name=__main___str;
}
......@@ -1235,9 +1234,6 @@ save_string(Picklerobject *self, PyObject *args, int doput)
int i;
char c_str[5];
if ((size = PyString_Size(args)) < 0)
return -1;
if (size < 256) {
c_str[0] = SHORT_BINSTRING;
c_str[1] = size;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment