From 25b788a9edab812cac75c79d1fc1c6e8d9ee5ad7 Mon Sep 17 00:00:00 2001 From: Xinhe Zhou Date: Sat, 14 Dec 2019 07:38:36 -0600 Subject: [PATCH] fs/vfs/fs_open.c: Fix error in nx_vopen() function. 'va_start' is used in function with fixed args. 'va_start'/'va_end' should not be used in nx_vopen function, because it has fixed arguments. --- fs/vfs/fs_open.c | 2 -- tools/Makefile.win | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/fs/vfs/fs_open.c b/fs/vfs/fs_open.c index d908feacb9..0516b5db6e 100644 --- a/fs/vfs/fs_open.c +++ b/fs/vfs/fs_open.c @@ -120,9 +120,7 @@ int nx_vopen(FAR const char *path, int oflags, va_list ap) if ((oflags & (O_WRONLY | O_CREAT)) != 0) { - va_start(ap, oflags); mode = va_arg(ap, mode_t); - va_end(ap); } #endif diff --git a/tools/Makefile.win b/tools/Makefile.win index 8fbd1fe365..b6a472f142 100644 --- a/tools/Makefile.win +++ b/tools/Makefile.win @@ -38,7 +38,7 @@ export SHELL=cmd TOPDIR := ${shell echo %CD%} -include $(TOPDIR)\.config -include $(TOPDIR)/.version --include $(TOPDIR)\tools\Config.mk +include $(TOPDIR)\tools\Config.mk -include $(TOPDIR)\Make.defs # In case .version file does not exist