Merge "use device serial number to seed RNG for generating ANDROID_ID"
diff --git a/core/java/android/widget/FastScroller.java b/core/java/android/widget/FastScroller.java
index 67c0def..13fe5a4 100644
--- a/core/java/android/widget/FastScroller.java
+++ b/core/java/android/widget/FastScroller.java
@@ -428,12 +428,21 @@
                 if (mListAdapter == null && mList != null) {
                     getSectionsFromIndexer();
                 }
+                if (mList != null) {
+                    mList.requestDisallowInterceptTouchEvent(true);
+                }
 
                 cancelFling();
                 return true;
             }
-        } else if (action == MotionEvent.ACTION_UP) {
+        } else if (action == MotionEvent.ACTION_UP || action == MotionEvent.ACTION_CANCEL) {
             if (mState == STATE_DRAGGING) {
+                if (mList != null) {
+                    // ViewGroup does the right thing already, but there might
+                    // be other classes that don't properly reset on touch-up,
+                    // so do this explicitly just in case.
+                    mList.requestDisallowInterceptTouchEvent(false);
+                }
                 setState(STATE_VISIBLE);
                 final Handler handler = mHandler;
                 handler.removeCallbacks(mScrollFade);
diff --git a/core/jni/AndroidRuntime.cpp b/core/jni/AndroidRuntime.cpp
index fa1ee0d..1d22de3 100644
--- a/core/jni/AndroidRuntime.cpp
+++ b/core/jni/AndroidRuntime.cpp
@@ -656,6 +656,15 @@
         }
     }
 
+    /* enable poisoning of memory of freed objects */
+    property_get("dalvik.vm.gc.overwritefree", propBuf, "false");
+    if (strcmp(propBuf, "true") == 0) {
+        opt.optionString = "-Xgc:overwritefree";
+        mOptions.add(opt);
+    } else if (strcmp(propBuf, "false") != 0) {
+        LOGW("dalvik.vm.gc.overwritefree should be 'true' or 'false'");
+    }
+
     /* enable debugging; set suspend=y to pause during VM init */
 #ifdef HAVE_ANDROID_OS
     /* use android ADB transport */