Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
Nodemcu Firmware
Commits
b8e00120
Commit
b8e00120
authored
Oct 13, 2016
by
Arnim Läuger
Committed by
Marcel Stör
Oct 13, 2016
Browse files
fix dereferencing NULL pointer in vfs_errno() (#1539)
parent
025805b0
Changes
1
Hide whitespace changes
Inline
Side-by-side
app/platform/vfs.c
View file @
b8e00120
...
@@ -355,11 +355,12 @@ sint32_t vfs_chdir( const char *path )
...
@@ -355,11 +355,12 @@ sint32_t vfs_chdir( const char *path )
sint32_t
vfs_errno
(
const
char
*
name
)
sint32_t
vfs_errno
(
const
char
*
name
)
{
{
vfs_fs_fns
*
fs_fns
;
vfs_fs_fns
*
fs_fns
;
const
char
*
normname
=
normalize_path
(
name
);
char
*
outname
;
char
*
outname
;
if
(
!
name
)
name
=
""
;
// current drive
if
(
!
name
)
name
=
""
;
// current drive
const
char
*
normname
=
normalize_path
(
name
);
#ifdef BUILD_SPIFFS
#ifdef BUILD_SPIFFS
if
(
fs_fns
=
myspiffs_realm
(
normname
,
&
outname
,
FALSE
))
{
if
(
fs_fns
=
myspiffs_realm
(
normname
,
&
outname
,
FALSE
))
{
return
fs_fns
->
ferrno
(
);
return
fs_fns
->
ferrno
(
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment