diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2003-01-27 16:13:28 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2003-01-27 16:13:28 +0000 |
commit | 62e080e114efa466b82e29635d4436a38bd29975 (patch) | |
tree | a6a0cf3e8860a247c703ab49575f0f3cdfb616f1 | |
parent | 2003-01-27 Juan Zamorano <jzamora@fi.upm.es> (diff) | |
download | rtems-62e080e114efa466b82e29635d4436a38bd29975.tar.bz2 |
2003-01-27 Dan Smisko <dan@balanced.com>
* monitor/mon-command.c: Correct two potential NULL references.
-rw-r--r-- | cpukit/libmisc/ChangeLog | 4 | ||||
-rw-r--r-- | cpukit/libmisc/monitor/mon-command.c | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/cpukit/libmisc/ChangeLog b/cpukit/libmisc/ChangeLog index 97b5e902a7..b4ce8bedc1 100644 --- a/cpukit/libmisc/ChangeLog +++ b/cpukit/libmisc/ChangeLog @@ -1,3 +1,7 @@ +2003-01-27 Dan Smisko <dan@balanced.com> + + * monitor/mon-command.c: Correct two potential NULL references. + 2002-01-25 Ralf Corsepius <corsepiu@faw.uni-ulm.de> * configure.ac: Fix tests for GCC. diff --git a/cpukit/libmisc/monitor/mon-command.c b/cpukit/libmisc/monitor/mon-command.c index 54f35cb04f..0603804823 100644 --- a/cpukit/libmisc/monitor/mon-command.c +++ b/cpukit/libmisc/monitor/mon-command.c @@ -551,7 +551,7 @@ rtems_monitor_command_lookup( */ if (found_it) { - if (table->command_function == 0) + if (found_it->command_function == 0) return 0; return found_it; @@ -686,7 +686,7 @@ rtems_monitor_command_usage( while (command) { - int len = strlen (command->command); + int len = command->command ? strlen (command->command) : 0 ; if (len > max_cmd_len) max_cmd_len = len; |