Kaydet (Commit) 0f868375 authored tarafından Guido van Rossum's avatar Guido van Rossum

Check errors returned by recursive call to Split().

üst fc93f75d
...@@ -261,13 +261,20 @@ Split (self, list) ...@@ -261,13 +261,20 @@ Split (self, list)
v = PyString_FromString (""); v = PyString_FromString ("");
else if (argc == 1) else if (argc == 1)
v = PyString_FromString (argv[0]); v = PyString_FromString (argv[0]);
else else if ((v = PyTuple_New (argc)) != NULL)
{ {
int i; int i;
PyObject *w;
v = PyTuple_New (argc);
for (i = 0; i < argc; i++) for (i = 0; i < argc; i++) {
PyTuple_SetItem (v, i, Split (self, argv[i])); if ((w = Split (self, argv[i])) == NULL)
{
Py_DECREF(v);
v = NULL;
break;
}
PyTuple_SetItem (v, i, w);
}
} }
ckfree (FREECAST argv); ckfree (FREECAST argv);
......
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