[CFL] Add check to get_uv_mode

Check that the uv_mode is not UV_MODE_INVALID

Change-Id: Ibbe342397b47d94b0b6823d558a7ed713adef314
diff --git a/av1/common/blockd.h b/av1/common/blockd.h
index 873e61c..c055c98 100644
--- a/av1/common/blockd.h
+++ b/av1/common/blockd.h
@@ -396,6 +396,7 @@
 
 #if CONFIG_CFL
 static INLINE PREDICTION_MODE get_uv_mode(UV_PREDICTION_MODE mode) {
+  assert(mode < UV_INTRA_MODES);
   static const PREDICTION_MODE uv2y[UV_INTRA_MODES] = {
     DC_PRED,        // UV_DC_PRED
     V_PRED,         // UV_V_PRED