prevent core dump for old getargs() with NULL arg
diff --git a/Python/getargs.c b/Python/getargs.c
index 605cb01..15cd4e6 100644
--- a/Python/getargs.c
+++ b/Python/getargs.c
@@ -179,6 +179,13 @@
 			return 0;
 		}
 		else if (min == 1 && max == 1) {
+			if (args == NULL) {
+				sprintf(msgbuf,
+					"%s requires at least one argument",
+					fname==NULL ? "function" : fname);
+				err_setstr(TypeError, msgbuf);
+				return 0;
+			}
 			msg = convertitem(args, &format, &va, levels, msgbuf);
 			if (msg == NULL)
 				return 1;