aboutsummaryrefslogtreecommitdiffstats
path: root/plugin_python.c
diff options
context:
space:
mode:
authorReinhard Tartler <siretart@tauware.de>2011-04-27 19:28:49 +0200
committerReinhard Tartler <siretart@tauware.de>2011-04-27 19:28:49 +0200
commit4cd9f4d9071a672debd83b4cc1c5d57dc63b8549 (patch)
tree095c755ba2cc77198dfc85b45afd129b1e638d56 /plugin_python.c
parent18590c85ce8d68b155828a4aa400105812aeb75d (diff)
parent181cec4348da40331b3e8ab365732c025ec149b2 (diff)
downloadlcd4linux-4cd9f4d9071a672debd83b4cc1c5d57dc63b8549.tar.gz
New upstream snapshot
Diffstat (limited to 'plugin_python.c')
-rw-r--r--plugin_python.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/plugin_python.c b/plugin_python.c
index 0a4a1fd..70ea9dc 100644
--- a/plugin_python.c
+++ b/plugin_python.c
@@ -1,5 +1,5 @@
-/* $Id: plugin_python.c 728 2007-01-14 11:14:38Z michael $
- * $URL: https://ssl.bulix.org/svn/lcd4linux/branches/0.10.1/plugin_python.c $
+/* $Id: plugin_python.c 1086 2010-01-19 14:26:33Z mzuther $
+ * $URL: https://ssl.bulix.org/svn/lcd4linux/trunk/plugin_python.c $
*
* Python plugin
*
@@ -32,6 +32,7 @@
*
*/
+#include "config.h"
#include <Python.h>
#include "debug.h"
#include "plugin.h"
@@ -92,6 +93,8 @@ static void pyt_exec_str(RESULT * result, const char *module, const char *functi
} else {
Py_DECREF(pModule);
error("Python call failed (\"%s.%s\")", module, function);
+ /* print traceback on stderr */
+ PyErr_PrintEx(0);
SetResult(&result, R_STRING, "");
return;
}
@@ -102,6 +105,8 @@ static void pyt_exec_str(RESULT * result, const char *module, const char *functi
Py_DECREF(pModule);
} else {
error("Failed to load python module \"%s\"", module);
+ /* print traceback on stderr */
+ PyErr_PrintEx(0);
}
SetResult(&result, R_STRING, "");
return;