This fixes a null pointer dereference at least Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>