pyxattr: Remove unnecessary hacks.
authorJelmer Vernooij <jelmer@samba.org>
Thu, 21 Jan 2010 03:18:19 +0000 (16:18 +1300)
committerJelmer Vernooij <jelmer@samba.org>
Thu, 21 Jan 2010 03:18:19 +0000 (16:18 +1300)
source4/scripting/python/pyxattr_native.c
source4/scripting/python/pyxattr_tdb.c

index 7cff42cebeb493a567740b25d12287272e9faa52..969ee7d4162380715180172e0ff57314203bbb4e 100644 (file)
@@ -19,7 +19,6 @@
 */
 
 #include <Python.h>
-#include "version.h"
 #include "includes.h"
 #include "librpc/ndr/libndr.h"
 #include "lib/util/wrap_xattr.h"
@@ -112,19 +111,8 @@ void initxattr_native(void)
 
        m = Py_InitModule3("xattr_native", py_xattr_methods,
                           "Python bindings for xattr manipulation.");
+
        if (m == NULL)
                return;
-
-       PyModule_AddObject(m, "version", PyString_FromString(SAMBA_VERSION_STRING));
-
-       /* one of the most annoying things about python scripts is
-          that they don't die when you hit control-C. This fixes that
-          sillyness. As we do all database operations using
-          transactions, this is also safe. In fact, not dying
-          immediately is unsafe as we could end up treating the
-          control-C exception as a different error and try to modify
-          as database incorrectly
-       */
-       signal(SIGINT, SIG_DFL);
 }
 
index aa511fa5e795eca1d3e221a7db691171e7728515..071d4374f2bd97b82e2b8b32d5e8694270244369 100644 (file)
@@ -19,7 +19,6 @@
 */
 
 #include <Python.h>
-#include "version.h"
 #include "includes.h"
 #include "../tdb/include/tdb.h"
 #include "tdb_wrap.h"
@@ -116,17 +115,5 @@ void initxattr_tdb(void)
                           "Python bindings for xattr manipulation.");
        if (m == NULL)
                return;
-
-       PyModule_AddObject(m, "version", PyString_FromString(SAMBA_VERSION_STRING));
-
-       /* one of the most annoying things about python scripts is
-          that they don't die when you hit control-C. This fixes that
-          sillyness. As we do all database operations using
-          transactions, this is also safe. In fact, not dying
-          immediately is unsafe as we could end up treating the
-          control-C exception as a different error and try to modify
-          as database incorrectly
-       */
-       signal(SIGINT, SIG_DFL);
 }