mkvparser,VideoTrack::Parse: fix leak on error

of colour_space; use a unique_ptr to capture the return from
UnserializeString. this is similar to other fixes in this function.

Bug: b/152133942
Change-Id: I6ff4c8ed278b782717a92bb21977740a61205931
diff --git a/mkvparser/mkvparser.cc b/mkvparser/mkvparser.cc
index fe0f25e..acbe41a 100644
--- a/mkvparser/mkvparser.cc
+++ b/mkvparser/mkvparser.cc
@@ -5309,7 +5309,7 @@
   long long stereo_mode = 0;
 
   double rate = 0.0;
-  char* colour_space = NULL;
+  std::unique_ptr<char[]> colour_space_ptr;
 
   IMkvReader* const pReader = pSegment->m_pReader;
 
@@ -5386,9 +5386,11 @@
         projection_ptr.reset(projection);
       }
     } else if (id == libwebm::kMkvColourSpace) {
+      char* colour_space = NULL;
       const long status = UnserializeString(pReader, pos, size, colour_space);
       if (status < 0)
         return status;
+      colour_space_ptr.reset(colour_space);
     }
 
     pos += size;  // consume payload
@@ -5420,7 +5422,7 @@
   pTrack->m_stereo_mode = stereo_mode;
   pTrack->m_rate = rate;
   pTrack->m_colour = colour_ptr.release();
-  pTrack->m_colour_space = colour_space;
+  pTrack->m_colour_space = colour_space_ptr.release();
   pTrack->m_projection = projection_ptr.release();
 
   pResult = pTrack;