diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-01-13 08:21:18 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-01-13 08:21:18 -0600 |
commit | df4d1ee71b6dd23755e23b95dc88898f0635816c (patch) | |
tree | c01b2a197960e45013e4c091ef2004332986d908 | |
parent | e25eae1f17c966060e1087bd332e530ca6667a8d (diff) | |
download | nuttx-df4d1ee71b6dd23755e23b95dc88898f0635816c.tar.gz nuttx-df4d1ee71b6dd23755e23b95dc88898f0635816c.tar.bz2 nuttx-df4d1ee71b6dd23755e23b95dc88898f0635816c.zip |
Cosmetic clean-up in preparation for TCP write buffering change
-rw-r--r-- | apps/nshlib/nsh_dbgcmds.c | 4 | ||||
-rw-r--r-- | apps/nshlib/nsh_parse.c | 6 | ||||
-rw-r--r-- | nuttx/include/nuttx/math.h | 9 | ||||
-rw-r--r-- | nuttx/libc/spawn/lib_psa_dump.c | 2 |
4 files changed, 15 insertions, 6 deletions
diff --git a/apps/nshlib/nsh_dbgcmds.c b/apps/nshlib/nsh_dbgcmds.c index 4b8646ef7..e0bf79de1 100644 --- a/apps/nshlib/nsh_dbgcmds.c +++ b/apps/nshlib/nsh_dbgcmds.c @@ -188,6 +188,7 @@ int cmd_mb(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv) nsh_output(vtbl, "\n", *ptr); } } + return ret; } #endif @@ -241,6 +242,7 @@ int cmd_mh(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv) nsh_output(vtbl, "\n", *ptr); } } + return ret; } #endif @@ -286,6 +288,7 @@ int cmd_mw(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv) nsh_output(vtbl, "\n", *ptr); } } + return ret; } #endif @@ -327,6 +330,7 @@ void nsh_dumpbuffer(FAR struct nsh_vtbl_s *vtbl, const char *msg, sprintf(&line[strlen(line)], "%c", ch >= 0x20 && ch <= 0x7e ? ch : '.'); } } + nsh_output(vtbl, "%s\n", line); } } diff --git a/apps/nshlib/nsh_parse.c b/apps/nshlib/nsh_parse.c index fe9a3d4c6..4ac6980df 100644 --- a/apps/nshlib/nsh_parse.c +++ b/apps/nshlib/nsh_parse.c @@ -143,14 +143,17 @@ static FAR char *nsh_filecat(FAR struct nsh_vtbl_s *vtbl, FAR char *s1, static FAR char *nsh_cmdparm(FAR struct nsh_vtbl_s *vtbl, FAR char *cmdline, FAR char **allocation); #endif + #ifdef CONFIG_NSH_ARGCAT static FAR char *nsh_strcat(FAR struct nsh_vtbl_s *vtbl, FAR char *s1, FAR const char *s2); #endif + #ifndef CONFIG_DISABLE_ENVIRON static FAR char *nsh_envexpand(FAR struct nsh_vtbl_s *vtbl, FAR char *varname); #endif + static FAR char *nsh_argexpand(FAR struct nsh_vtbl_s *vtbl, FAR char *cmdline, FAR char **allocation); static FAR char *nsh_argument(FAR struct nsh_vtbl_s *vtbl, char **saveptr, @@ -171,6 +174,7 @@ static int nsh_nice(FAR struct nsh_vtbl_s *vtbl, FAR char **ppcmd, static int nsh_parse_cmdparm(FAR struct nsh_vtbl_s *vtbl, FAR char *cmdline, FAR const char *redirfile); #endif + static int nsh_parse_command(FAR struct nsh_vtbl_s *vtbl, FAR char *cmdline); /**************************************************************************** @@ -1001,7 +1005,7 @@ static FAR char *nsh_argexpand(FAR struct nsh_vtbl_s *vtbl, FAR char *cmdline, FAR char *result; FAR char *rptr; - /* Replace the backqutote with a NUL terminator and add the + /* Replace the backquote with a NUL terminator and add the * intervening character to the concatenated string. */ diff --git a/nuttx/include/nuttx/math.h b/nuttx/include/nuttx/math.h index d4277b802..c01963cff 100644 --- a/nuttx/include/nuttx/math.h +++ b/nuttx/include/nuttx/math.h @@ -57,15 +57,15 @@ * The port or the Rhombus math library was contributed by Darcy Gong. */ -#elif defined CONFIG_LIBM +#elif defined(CONFIG_LIBM) /**************************************************************************** * Copyright (C) 2009-2011 Nick Johnson <nickbjohnson4224 at gmail.com> - * + * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. - * + * * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR @@ -120,7 +120,8 @@ ****************************************************************************/ #if defined(__cplusplus) -extern "C" { +extern "C" +{ #endif /* General Functions ********************************************************/ diff --git a/nuttx/libc/spawn/lib_psa_dump.c b/nuttx/libc/spawn/lib_psa_dump.c index 4687e8338..b949d230a 100644 --- a/nuttx/libc/spawn/lib_psa_dump.c +++ b/nuttx/libc/spawn/lib_psa_dump.c @@ -124,4 +124,4 @@ void posix_spawnattr_dump(posix_spawnattr_t *attr) #endif } -#endif /* CONFIG_DEBUG */
\ No newline at end of file +#endif /* CONFIG_DEBUG */ |