[Media Common] Fix the kw issue

Check the ptr !=  nullptr before referece it.
1 file changed