You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
qemu/scripts/coccinelle/use-error_fatal.cocci

21 lines
350 B
Plaintext

@@
type T;
identifier FUN, RET;
expression list ARGS;
expression ERR, EC, FAIL;
@@
(
- T RET = FUN(ARGS, &ERR);
+ T RET = FUN(ARGS, &error_fatal);
|
- RET = FUN(ARGS, &ERR);
+ RET = FUN(ARGS, &error_fatal);
|
- FUN(ARGS, &ERR);
+ FUN(ARGS, &error_fatal);
)
- if (FAIL) {
- error_report_err(ERR);
- exit(EC);
- }