Re: [U-Boot] [PATCH] cmd_nand: fix crashing bug in nand read/write

2012-06-07 Thread Scott Wood
On 06/07/2012 12:19 PM, Steve Sakoman wrote: > Commit 418396e212b59bf907dbccad997ff50f7eb61b16 introduced a > bug that causes nand read and nand write to crash in strcmp > due to a null pointer. > > Root cause is that strchr(cmd, '.') returns a null pointer when > the input string does not contain

[U-Boot] [PATCH] cmd_nand: fix crashing bug in nand read/write

2012-06-07 Thread Steve Sakoman
Commit 418396e212b59bf907dbccad997ff50f7eb61b16 introduced a bug that causes nand read and nand write to crash in strcmp due to a null pointer. Root cause is that strchr(cmd, '.') returns a null pointer when the input string does not contain a '.' The strcmp function does not check for null point