IoCancelIrp jumping off into the weeds

Oh! So it could very well have had an invalid routine set. All of the places where it’s set in our code seem to be setting it to NULL from what I see but maybe it’s using some uninitialized memory. I’ll need to look more closely at the code around that region.

The Irp CancelRoutine field is set to null before your cancel routine is
called.

Well son of a gun! I think I found it. We have a cancel routine that works for both the receiver and pcap recorder but for some reason it was never getting set for the pcap filter IRPs. I went and hard-coded it and boom! No more crash.

I’ll need to formalize the fix to see why the original attempt to set the CancelRoutine wasn’t working but this is definitely the right path.

Thank you so much for all your help everyone.