Add move constructor/assignment operator to hidl_memory am: 0126889103 am: eef47bd374
am: 39ac871fbb

Change-Id: I414b9e9221a710b59f3868ba45e9cb002fab4cb9
diff --git a/base/HidlSupport.cpp b/base/HidlSupport.cpp
index 37f40c4..c7328d4 100644
--- a/base/HidlSupport.cpp
+++ b/base/HidlSupport.cpp
@@ -134,6 +134,7 @@
 }
 
 void hidl_handle::setTo(native_handle_t* handle, bool shouldOwn) {
+    freeHandle();
     mHandle = handle;
     mOwnsHandle = shouldOwn;
 }