Core: Fix null pointer deref if no file is found
Jeffrey Pfau jeffrey@endrift.com
Sat, 17 Sep 2016 12:41:54 -0700
1 files changed,
3 insertions(+),
0 deletions(-)
jump to
M
src/core/library.c
→
src/core/library.c
@@ -41,6 +41,9 @@ struct mCore* core;
if (!vf) { vf = VFileOpen(filename, O_RDONLY); } + if (!vf) { + return; + } core = mCoreFindVF(vf); if (core) { core->init(core);