From: Rob Browning Date: Mon, 23 Sep 2013 00:18:24 +0000 (-0500) Subject: Move _helper.c's Python.h back up (now to the top), because Python. X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=81ad1e6871827ec0fda7f5f93b646a8ea1c98c03;p=packages%2Fb%2Fbup.git Move _helper.c's Python.h back up (now to the top), because Python. Move the Python.h include in _helper.c to the top because Python says so: http://docs.python.org/2/c-api/intro.html#include-files Though according to this, it's been fixed upstream: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=206805 Which might explain why I didn't see the problem here. Thanks to Chandan Kumar for the report. Signed-off-by: Rob Browning --- diff --git a/lib/bup/_helpers.c b/lib/bup/_helpers.c index fe48511..de8f6f2 100644 --- a/lib/bup/_helpers.c +++ b/lib/bup/_helpers.c @@ -2,6 +2,11 @@ #define PY_SSIZE_T_CLEAN 1 #undef NDEBUG #include "../../config/config.h" + +// According to Python, its header has to go first: +// http://docs.python.org/2/c-api/intro.html#include-files +#include + #include #include #include @@ -29,7 +34,6 @@ #endif #include "bupsplit.h" -#include #if defined(FS_IOC_GETFLAGS) && defined(FS_IOC_SETFLAGS) #define BUP_HAVE_FILE_ATTRS 1