From 845ce3cbfd6972542b275c95eddfbb6e94469737 Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Fri, 13 Nov 2009 17:07:00 -0800 Subject: Don't allocate arbitrary-length buffers on the stack. A new LocalArray C++ class lets us specify a "reasonable" amount of stack to use, but transparently fall back to using the heap if we need more space. The three places I've chosen to use LocalArray in this patch are fairly random; all they have in common is that they're the places where we call GetStringUTFRegion. There are more places LocalArray will be useful: the java.io.File JNI in particular. Bug: 2257819 --- NativeCode.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'NativeCode.mk') diff --git a/NativeCode.mk b/NativeCode.mk index 0dfad3b..57c4903 100644 --- a/NativeCode.mk +++ b/NativeCode.mk @@ -74,7 +74,7 @@ $(foreach dir, \ # Extract out the allowed LOCAL_* variables. Note: $(sort) also # removes duplicates. -core_c_includes := $(sort $(LOCAL_C_INCLUDES) $(JNI_H_INCLUDE)) +core_c_includes := $(sort dalvik/libcore/include $(LOCAL_C_INCLUDES) $(JNI_H_INCLUDE)) core_shared_libraries := $(sort $(LOCAL_SHARED_LIBRARIES)) core_static_libraries := $(sort $(LOCAL_STATIC_LIBRARIES)) @@ -118,4 +118,4 @@ ifeq ($(WITH_HOST_DALVIK),true) # TODO: Figure out cacerts.bks for the host. -endif \ No newline at end of file +endif -- cgit v1.1