bind9/cocci/isc_event_allocat_never_fail.spatch

33 lines
382 B
Text

@@
statement S;
expression V;
@@
V = isc_event_allocate(...);
- if (V == NULL) S
@@
type T;
statement S;
expression V;
@@
V = (T *)isc_event_allocate(...);
- if (V == NULL) S
@@
statement S;
expression V;
@@
if (V == NULL) V = isc_event_allocate(...);
- if (V == NULL) S
@@
statement S1, S2;
expression V;
@@
V = isc_event_allocate(...);
- if (V == NULL) S1 else { S2 }
+ S2