Fixed hang in the case of multiple sps id.

The sps parameters used to detect change in
resolution/sps were incorrect. Made a fix to
use current sps from decoder context.

Bug: 38239864

Change-Id: I2d110e635ced32b3dc7f364e08a97d672fcbae37
(cherry picked from commit 8c6fe35f6d28f3e8c3a9f9458eea89eba858bded)
(cherry picked from commit ec3f58500066edee259942057e21489621fca9dd)
diff --git a/decoder/ih264d_parse_headers.c b/decoder/ih264d_parse_headers.c
index 352d605..d8c37a6 100644
--- a/decoder/ih264d_parse_headers.c
+++ b/decoder/ih264d_parse_headers.c
@@ -564,7 +564,10 @@
     /*--------------------------------------------------------------------*/
 
     ps_seq = ps_dec->pv_scratch_sps_pps;
-    *ps_seq = ps_dec->ps_sps[u1_seq_parameter_set_id];
+    if(ps_dec->i4_header_decoded & 1)
+    {
+        *ps_seq = *ps_dec->ps_cur_sps;
+    }
 
 
     if((ps_dec->i4_header_decoded & 1) && (ps_seq->u1_profile_idc != u1_profile_idc))