[PATCH 2/2] cmd: Add additional bounds checking in search_command.