]> granicus.if.org Git - python/commitdiff
Whoops, how did that get in there. :-) Revert all the parts of 51227 that were not...
authorNeal Norwitz <nnorwitz@gmail.com>
Sat, 12 Aug 2006 02:12:30 +0000 (02:12 +0000)
committerNeal Norwitz <nnorwitz@gmail.com>
Sat, 12 Aug 2006 02:12:30 +0000 (02:12 +0000)
Lib/test/regrtest.py
Objects/funcobject.c
Python/ceval.c
Python/pythonrun.c

index 8c416f1c43483e7f548382d942cf3ca551487711..4553838afcd6ef2f9287092e0ff7532f0476ed4d 100755 (executable)
@@ -123,7 +123,6 @@ option '-uall,-bsddb'.
 
 import os
 import sys
-import signal
 import getopt
 import random
 import warnings
@@ -290,12 +289,6 @@ def main(tests=None, testdir=None, verbose=0, quiet=False, generate=False,
     if single and fromfile:
         usage(2, "-s and -f don't go together!")
 
-    def handle_signal(*args):
-        raise RuntimeError('signal received %s' % args)
-
-    # Provide a traceback if we are terminated.
-    signal.signal(signal.SIGTERM, handle_signal)
-
     good = []
     bad = []
     skipped = []
index b972e086cb14a3e921c29be6d778f98ccdb9ca21..1ba74c5a926eb7963084313d1f061a4d466d900d 100644 (file)
@@ -486,10 +486,9 @@ function_call(PyObject *func, PyObject *arg, PyObject *kw)
        Py_ssize_t nk, nd;
 
        argdefs = PyFunction_GET_DEFAULTS(func);
-       /* XXX(nnorwitz): don't we know argdefs is either NULL or a tuple? */
        if (argdefs != NULL && PyTuple_Check(argdefs)) {
                d = &PyTuple_GET_ITEM((PyTupleObject *)argdefs, 0);
-               nd = PyTuple_GET_SIZE(argdefs);
+               nd = PyTuple_Size(argdefs);
        }
        else {
                d = NULL;
@@ -518,7 +517,7 @@ function_call(PyObject *func, PyObject *arg, PyObject *kw)
        result = PyEval_EvalCodeEx(
                (PyCodeObject *)PyFunction_GET_CODE(func),
                PyFunction_GET_GLOBALS(func), (PyObject *)NULL,
-               &PyTuple_GET_ITEM(arg, 0), PyTuple_GET_SIZE(arg),
+               &PyTuple_GET_ITEM(arg, 0), PyTuple_Size(arg),
                k, nk, d, nd,
                PyFunction_GET_CLOSURE(func));
 
index 6d2b17f1ea810cfdd6227d11521e607ab514f734..a0e8b30c0526fc430ce216e1365659f7de69d9db 100644 (file)
@@ -229,15 +229,6 @@ PyEval_InitThreads(void)
        main_thread = PyThread_get_thread_ident();
 }
 
-void
-_PyEval_FiniThreads(void)
-{
-       if (interpreter_lock)
-               PyThread_free_lock(interpreter_lock);
-       interpreter_lock = 0;
-       main_thread = 0;
-}
-
 void
 PyEval_AcquireLock(void)
 {
index 80f62324f3e1e333081c9453cadb362ead735472..88fd67c1e57ac19b1687b5229700e85a84342e64 100644 (file)
@@ -60,7 +60,6 @@ static void call_sys_exitfunc(void);
 static void call_ll_exitfuncs(void);
 extern void _PyUnicode_Init(void);
 extern void _PyUnicode_Fini(void);
-extern void _PyEval_FiniThreads(void);
 
 #ifdef WITH_THREAD
 extern void _PyGILState_Init(PyInterpreterState *, PyThreadState *);
@@ -462,8 +461,6 @@ Py_Finalize(void)
        _PyUnicode_Fini();
 #endif
 
-       _PyEval_FiniThreads();
-
        /* XXX Still allocated:
           - various static ad-hoc pointers to interned strings
           - int and float free list blocks