From b7fc30410919f3b0aba4b17bc66803e71bccab46 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Wed, 11 Sep 1996 22:51:25 +0000 Subject: Correct typo in setattr: return -1 for error, not NULL --- Objects/object.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Objects/object.c b/Objects/object.c index 9c99ea2..b1025ef 100644 --- a/Objects/object.c +++ b/Objects/object.c @@ -370,7 +370,7 @@ setattr(v, name, w) int res; s = newstringobject(name); if (s == NULL) - return NULL; + return -1; res = (*v->ob_type->tp_setattro)(v, s, w); XDECREF(s); return res; -- cgit v0.12