diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-01-14 13:30:22 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-01-14 13:30:22 -0600 |
commit | 909af806c753228e9ae279432993c93e9180b54f (patch) | |
tree | 943750805050126fae960ac09211e22d8ca2cef5 /apps/nshlib/nsh_dbgcmds.c | |
parent | 37a1adc0053c37b3bc70379f489f93359724186a (diff) | |
download | px4-nuttx-909af806c753228e9ae279432993c93e9180b54f.tar.gz px4-nuttx-909af806c753228e9ae279432993c93e9180b54f.tar.bz2 px4-nuttx-909af806c753228e9ae279432993c93e9180b54f.zip |
Changes to get PX4 config to build. Also some warning removal
Diffstat (limited to 'apps/nshlib/nsh_dbgcmds.c')
-rw-r--r-- | apps/nshlib/nsh_dbgcmds.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/apps/nshlib/nsh_dbgcmds.c b/apps/nshlib/nsh_dbgcmds.c index e0bf79de1..15ce9498b 100644 --- a/apps/nshlib/nsh_dbgcmds.c +++ b/apps/nshlib/nsh_dbgcmds.c @@ -89,7 +89,7 @@ struct dbgmem_s * Name: mem_parse ****************************************************************************/ -int mem_parse(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv, +static int mem_parse(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv, struct dbgmem_s *mem) { char *pcvalue = strchr(argv[1], '='); @@ -148,8 +148,8 @@ int cmd_mb(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv) { struct dbgmem_s mem; volatile uint8_t *ptr; + unsigned int i; int ret; - int i; ret = mem_parse(vtbl, argc, argv, &mem); if (ret == 0) @@ -202,15 +202,17 @@ int cmd_mh(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv) { struct dbgmem_s mem; volatile uint16_t *ptr; + unsigned int i; int ret; - int i; ret = mem_parse(vtbl, argc, argv, &mem); if (ret == 0) { /* Loop for the number of requested bytes */ - for (i = 0, ptr = (volatile uint16_t*)mem.dm_addr; i < mem.dm_count; i += 2, ptr++) + for (i = 0, ptr = (volatile uint16_t*)mem.dm_addr; + i < mem.dm_count; + i += 2, ptr++) { /* Print the value at the address */ @@ -256,8 +258,8 @@ int cmd_mw(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv) { struct dbgmem_s mem; volatile uint32_t *ptr; + unsigned int i; int ret; - int i; ret = mem_parse(vtbl, argc, argv, &mem); if (ret == 0) |