From b721fb76c6c96232be77533f149abb25a670e57e Mon Sep 17 00:00:00 2001 From: jianghaosen Date: Fri, 25 Aug 2017 21:01:17 +0800 Subject: [PATCH] fix(row926): a bug that filename is empty when parse glb when parse glb, filename maybe a empty value, it will be wrong --- tiny_gltf.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tiny_gltf.h b/tiny_gltf.h index c3a6fb1..efd1e1e 100644 --- a/tiny_gltf.h +++ b/tiny_gltf.h @@ -923,7 +923,7 @@ static bool LoadExternalFile(std::vector *out, std::string *err, paths.push_back("."); std::string filepath = FindFile(paths, filename); - if (filepath.empty()) { + if (filepath.empty() || filename.empty()) { if (err) { (*err) += "File not found : " + filename + "\n"; }