Cleanup various clang warnings, use unique_ptrs in several places

Change-Id: I347904b25e51fcc7de14b1e72f1acd0f6ba26f3f
diff --git a/libs/hwui/Interpolator.cpp b/libs/hwui/Interpolator.cpp
index 2623f53..e1b0fc3 100644
--- a/libs/hwui/Interpolator.cpp
+++ b/libs/hwui/Interpolator.cpp
@@ -88,14 +88,12 @@
     return t * t * ((mTension + 1) * t + mTension) + 1.0f;
 }
 
-LUTInterpolator::LUTInterpolator(float* values, size_t size) {
-    mValues = values;
-    mSize = size;
+LUTInterpolator::LUTInterpolator(float* values, size_t size)
+    : mValues(values)
+    , mSize(size) {
 }
 
 LUTInterpolator::~LUTInterpolator() {
-    delete mValues;
-    mValues = 0;
 }
 
 float LUTInterpolator::interpolate(float input) {
@@ -112,7 +110,7 @@
 
     LOG_ALWAYS_FATAL_IF(i1 < 0 || i2 < 0, "negatives in interpolation!"
             " i1=%d, i2=%d, input=%f, lutpos=%f, size=%zu, values=%p, ipart=%f, weight=%f",
-            i1, i2, input, lutpos, mSize, mValues, ipart, weight);
+            i1, i2, input, lutpos, mSize, mValues.get(), ipart, weight);
 
     float v1 = mValues[i1];
     float v2 = mValues[i2];