jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=fbd0a516072403eac1a3c81ead04e73f9e63cb23

commit fbd0a516072403eac1a3c81ead04e73f9e63cb23
Author: Jean-Philippe Andre <jp.an...@samsung.com>
Date:   Tue Jul 28 15:13:59 2015 +0900

    Evas filters: Fix order of header file includes
    
    This fixes filters on Ubuntu 32 bits.
    
    This was one hell of a weird bug to track down. Everything worked
    like a charm on my 64 bit machines, but filters would simply fail
    for no good reason: a safety check sees a NULL pointer when clearly
    it was properly allocated.
    
    Just after entering a function, the content of an RGBA_Image would
    change, even though there was no memory write there. This made the
    image data pointer NULL, and filters would fail miserably.
    
    So I printed out the contents of the RGBA_Image, they changed. But
    the memory itself had not changed. The size of the struct itself
    had changed when jumping from one file to another! But its definition
    had not! Non-sense!
    
    Unless of course a system header file was included before config.h
    and ino_t or off_t would switch between 32 and 64 bits...
    
    @fix
---
 src/lib/evas/filters/evas_filter_blur.c   | 6 +++---
 src/lib/evas/filters/evas_filter_bump.c   | 4 ++--
 src/lib/evas/filters/evas_filter_parser.c | 8 ++------
 3 files changed, 7 insertions(+), 11 deletions(-)

diff --git a/src/lib/evas/filters/evas_filter_blur.c 
b/src/lib/evas/filters/evas_filter_blur.c
index 4c375a7..fd444cc 100644
--- a/src/lib/evas/filters/evas_filter_blur.c
+++ b/src/lib/evas/filters/evas_filter_blur.c
@@ -1,9 +1,9 @@
-#include <math.h>
-#include <time.h>
-
 #include "evas_filter.h"
 #include "evas_filter_private.h"
 
+#include <math.h>
+#include <time.h>
+
 static int
 _box_blur_auto_radius(int *radii, int r)
 {
diff --git a/src/lib/evas/filters/evas_filter_bump.c 
b/src/lib/evas/filters/evas_filter_bump.c
index 60a9798..6155e65 100644
--- a/src/lib/evas/filters/evas_filter_bump.c
+++ b/src/lib/evas/filters/evas_filter_bump.c
@@ -1,10 +1,10 @@
 /* Simple bump map algorithms for the software engine */
 
-#include <math.h>
-
 #include "evas_filter_private.h"
 #include "evas_blend_private.h"
 
+#include <math.h>
+
 #ifdef CLAMP
 # undef CLAMP
 #endif
diff --git a/src/lib/evas/filters/evas_filter_parser.c 
b/src/lib/evas/filters/evas_filter_parser.c
index ce5fa1d..e5fef55 100644
--- a/src/lib/evas/filters/evas_filter_parser.c
+++ b/src/lib/evas/filters/evas_filter_parser.c
@@ -1,15 +1,11 @@
+#include "evas_filter_private.h"
+
 #include <stdarg.h>
 
 #include <lua.h>
 #include <lualib.h>
 #include <lauxlib.h>
 
-#include "evas_filter_private.h"
-
-#if LUA_VERSION_NUM == 502
-# define LUA52 1
-#endif
-
 #define FILTERS_LEGACY_COMPAT
 
 #define EVAS_FILTER_MODE_GROW   (EVAS_FILTER_MODE_LAST+1)

-- 


Reply via email to