summaryrefslogtreecommitdiff
path: root/apps/nshlib
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-11-12 14:23:14 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-11-12 14:23:14 -0600
commit97034d23851f2f1d6688a2cd45d517ecd72ef6dc (patch)
tree9db917c5f07d554b680abb0f5ccbbb365fe67322 /apps/nshlib
parentdf417a0b5bc42776d948f196ba9c36f004d1eae0 (diff)
downloadnuttx-97034d23851f2f1d6688a2cd45d517ecd72ef6dc.tar.gz
nuttx-97034d23851f2f1d6688a2cd45d517ecd72ef6dc.tar.bz2
nuttx-97034d23851f2f1d6688a2cd45d517ecd72ef6dc.zip
Emit a warning if number of arguments to builtin or file app can be truncated
Diffstat (limited to 'apps/nshlib')
-rw-r--r--apps/nshlib/nsh.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/apps/nshlib/nsh.h b/apps/nshlib/nsh.h
index d726b5253..c06d4e910 100644
--- a/apps/nshlib/nsh.h
+++ b/apps/nshlib/nsh.h
@@ -454,6 +454,12 @@
# endif
#endif
+#if defined(CONFIG_NSH_BUILTIN_APPS) || defined(CONFIG_NSH_FILE_APPS)
+# if CONFIG_NSH_MAXARGUMENTS > CONFIG_MAX_TASK_ARGS
+# warning Number of built-in and file task arguments will be truncated to CONFIG_MAX_TASK_ARGS
+# endif
+#endif
+
/* Argument list size
*
* argv[0]: The command name.