transport: fix segfault in setup_command_handler()

Commit 93f2afa45f dropped the sentinel off the end
of the command_registrants[] array.  The loop immediately
following the initialization will walk right off the end.

Signed-off-by: Stacey Sheldon <stac@solidgoldbomb.org>
This commit is contained in:
Stacey Sheldon 2010-07-04 16:19:02 -04:00 committed by Øyvind Harboe
parent db8b99aed6
commit 1e0f898415
1 changed files with 1 additions and 0 deletions

View File

@ -235,6 +235,7 @@ struct command_context *setup_command_handler(Jim_Interp *interp)
&nand_register_commands,
&pld_register_commands,
&mflash_register_commands,
NULL
};
for (unsigned i = 0; NULL != command_registrants[i]; i++)
{