This calls send_v2_notification. Do we know that st != NULL? If not, the passert and the DBG_log will segfault. If we do know st != NULL, would it not be better to call send_v2_notification_from_state? That would seem to be simpler and clearer. Or is there a problem with getting the right cookies out?