qat: fix null pointer dereferencing