If inspect_tx is NULL here we pass the NULL ptr to the engine->Callbacks, at least some seem unable to deal with this. As we check the result of AppLayerGetTx elsewhere, I think we should do so here as well.