intel/tools/error_decode: Simply error message handling
In the code path without arguments it tries 3 different paths and error messages are overwritten one by other, in this case any of those error messages are irrelevant. For the code path with arguments is similar, as it already have a fprintf(stderr) in the caller of open_error_state_file(). Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Signed-off-by: José Roberto de Souza <jose.souza@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27728>
This commit is contained in:
committed by
Marge Bot
parent
70e2384f8f
commit
77484ab6cf
@@ -861,17 +861,8 @@ open_error_state_file(const char *path)
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (!file) {
|
||||
fprintf(stderr, "Failed to find i915_error_state beneath %s\n",
|
||||
path);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
} else {
|
||||
file = fopen(path, "r");
|
||||
if (!file) {
|
||||
fprintf(stderr, "Failed to open %s: %s\n", path, strerror(errno));
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
}
|
||||
|
||||
return file;
|
||||
|
||||
Reference in New Issue
Block a user