diff options
author | 2017-05-19 18:56:34 +0000 | |
---|---|---|
committer | 2017-05-19 18:56:34 +0000 | |
commit | 5c865e5d25501f4edd2af960efbd28c3822b22db (patch) | |
tree | a85bb3071a1156a735de48621b9d1f3e91402629 | |
parent | 2ad2b55dbb42443c5c00484478afa55e97ec4770 (diff) | |
parent | f5c237480480f71d9eee91ffc566dfc8b0604c76 (diff) |
Merge "DO NOT MERGE Revert "Logging for catching memory issue in Parcel"" into oc-dev am: 1967749cdc
am: f5c2374804
Change-Id: I2785c388d27537ba4c5671b0398ff33628be901d
-rw-r--r-- | libs/binder/Parcel.cpp | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/libs/binder/Parcel.cpp b/libs/binder/Parcel.cpp index 6fefb38199..aec8f107a3 100644 --- a/libs/binder/Parcel.cpp +++ b/libs/binder/Parcel.cpp @@ -2547,16 +2547,8 @@ status_t Parcel::continueWrite(size_t desired) objectsSize = 0; } else { while (objectsSize > 0) { - if (mObjects[objectsSize-1] < desired) { - // Check for an object being sliced - if (desired < mObjects[objectsSize-1] + sizeof(flat_binder_object)) { - ALOGE("Attempt to shrink Parcel would slice an objects allocated memory"); - return UNKNOWN_ERROR + 0xBADF10; - } + if (mObjects[objectsSize-1] < desired) break; - } - // STOPSHIP: Above code to be replaced with following commented code: - // if (mObjects[objectsSize-1] + sizeof(flat_binder_object) <= desired) break; objectsSize--; } } |