lib: use a critical warning when unable to open a data file

Signed-off-by: Thomas Wood <thomas.wood@intel.com>
This commit is contained in:
Thomas Wood
2015-04-13 12:09:48 +01:00
parent 8b3082a40e
commit 90dadcd0da
2 changed files with 6 additions and 4 deletions
+5
View File
@@ -1751,5 +1751,10 @@ FILE *__igt_fopen_data(const char* igt_srcdir, const char* igt_datadir,
snprintf(path, sizeof(path), "%s/%s", igt_srcdir, filename);
fp = fopen(path, "r");
}
if (!fp)
igt_critical("Could not open data file \"%s\": %s", filename,
strerror(errno));
return fp;
}