[pypy-commit] pypy remove-PYPY_NOT_MAIN_FILE: Fixes for the signal module

amauryfa noreply at buildbot.pypy.org
Thu Sep 6 00:25:09 CEST 2012


Author: Amaury Forgeot d'Arc <amauryfa at gmail.com>
Branch: remove-PYPY_NOT_MAIN_FILE
Changeset: r57168:6d36cccdbb2c
Date: 2012-09-06 00:22 +0200
http://bitbucket.org/pypy/pypy/changeset/6d36cccdbb2c/

Log:	Fixes for the signal module

diff --git a/pypy/translator/c/src/signals.c b/pypy/translator/c/src/signals.c
--- a/pypy/translator/c/src/signals.c
+++ b/pypy/translator/c/src/signals.c
@@ -37,6 +37,12 @@
    pypysig_flags could be set. */
 static int wakeup_fd = -1;
 
+#undef pypysig_getaddr_occurred
+void *pypysig_getaddr_occurred(void)
+{
+    return (void *)(&pypysig_counter); 
+}
+
 void pypysig_ignore(int signum)
 {
 #ifdef SA_RESTART
diff --git a/pypy/translator/c/src/signals.h b/pypy/translator/c/src/signals.h
--- a/pypy/translator/c/src/signals.h
+++ b/pypy/translator/c/src/signals.h
@@ -22,7 +22,6 @@
 /* some C tricks to get/set the variable as efficiently as possible:
    use macros when compiling as a stand-alone program, but still
    export a function with the correct name for testing */
-#undef pypysig_getaddr_occurred
 void *pypysig_getaddr_occurred(void);
 #define pypysig_getaddr_occurred()   ((void *)(&pypysig_counter))
 


More information about the pypy-commit mailing list