media lib bug fix