Project

General

Profile

Actions

Optimization #4496

closed

decode: remove NULL checks after header casts

Added by Victor Julien 4 months ago. Updated 4 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Effort:
Difficulty:
Label:

Description

Decoders should never be called with a NULL pointer as their pkt input, yet a common pattern is that a NULL check is done after a cast of this pointer to a header specific type.

We should remove these checks but put a DEBUG_VALIDATE_BUG_ON(pkt == NULL); at the top of each decode function. This way fuzzing can try to falsify this assumption.

Actions #1

Updated by Jeff Lucovsky 4 months ago

  • Status changed from Assigned to In Progress
Actions #2

Updated by Jeff Lucovsky 4 months ago

  • Status changed from In Progress to In Review
Actions #3

Updated by Jeff Lucovsky 4 months ago

  • Status changed from In Review to Closed
Actions

Also available in: Atom PDF