OSDN Git Service

Add missing includes.
authorDan Albert <danalbert@google.com>
Tue, 26 Jul 2016 22:06:10 +0000 (15:06 -0700)
committerDan Albert <danalbert@google.com>
Wed, 27 Jul 2016 17:35:17 +0000 (10:35 -0700)
These files all use malloc/free but never include it. It looks like
the NDK headers leak stdlib.h through something that was being
included, but the updated headers don't have that mess.

Test: mma
Change-Id: Ia34a2d74f382f88476708e31da819ea18ab0aa4f

jni/filters/geometry.c
jni/filters/highlight.c
jni/filters/redEyeMath.c
jni/filters/shadows.c
jni/filters/wbalance.c

index 84a044c..b01e5e0 100644 (file)
  * limitations under the License.
  */
 
-#include "filters.h"
 #include <stdio.h>
+#include <stdlib.h>
+
+#include "filters.h"
 
 static __inline__ void flipVertical(char * source, int srcWidth, int srcHeight, char * destination, int dstWidth, int dstHeight){
     //Vertical
index fe9b88f..567a216 100644 (file)
@@ -15,6 +15,8 @@
  */
 
 #include <math.h>
+#include <stdlib.h>
+
 #include "filters.h"
 
 void JNIFUNCF(ImageFilterHighlights, nativeApplyFilter, jobject bitmap,
index 26f3f76..9a16d60 100644 (file)
@@ -15,6 +15,8 @@
  */
 
 #include <math.h>
+#include <stdlib.h>
+
 #include "filters.h"
 
 int value(int r, int g, int b) {
index 38d64c8..5f802dd 100644 (file)
@@ -15,6 +15,8 @@
  */
 
 #include <math.h>
+#include <stdlib.h>
+
 #include "filters.h"
 
 void JNIFUNCF(ImageFilterShadows, nativeApplyFilter, jobject bitmap, jint width, jint height, float scale){
index 7592a42..99a7d2e 100644 (file)
@@ -14,6 +14,8 @@
  * limitations under the License.
  */
 
+#include <stdlib.h>
+
 #include "filters.h"
 
 void estmateWhite(unsigned char *src, int len, int *wr, int *wb, int *wg){