diff options
author | Peter Stuge <peter@stuge.se> | 2009-01-25 20:41:51 +0000 |
---|---|---|
committer | Peter Stuge <peter@stuge.se> | 2009-01-25 20:41:51 +0000 |
commit | 2cd767ce3aee41aafa6ab742292531ef1a85e5f7 (patch) | |
tree | 8c666a70866ccc8079c621239496594d46ff37e1 /flashrom.c | |
parent | 63f0c867ecba7c3dafdf811bfc6d3e1b0c8b919e (diff) | |
download | flashrom-2cd767ce3aee41aafa6ab742292531ef1a85e5f7.zip flashrom-2cd767ce3aee41aafa6ab742292531ef1a85e5f7.tar.gz |
Fix stupid off-by-one error in erase verification
As reported by Jody McIntyre. Thanks!
Corresponding to flashrom svn r389 and coreboot v2 svn r3894.
Signed-off-by: Peter Stuge <peter@stuge.se>
Acked-by: Peter Stuge <peter@stuge.se>
Diffstat (limited to 'flashrom.c')
-rw-r--r-- | flashrom.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -605,7 +605,7 @@ int main(int argc, char *argv[]) memcpy(buf, (const char *)flash->virtual_memory, size); else flash->read(flash, buf); - for (erasedbytes = 0; erasedbytes <= size; erasedbytes++) + for (erasedbytes = 0; erasedbytes < size; erasedbytes++) if (0xff != buf[erasedbytes]) { printf("FAILED!\n"); fprintf(stderr, "ERROR at 0x%08x: Expected=0xff, Read=0x%02x\n", |