mirror of
https://review.coreboot.org/flashrom.git
synced 2025-04-29 16:03:47 +02:00
Check that a filename was specified also when using force read
Corresponding to flashrom svn r322 and coreboot v2 svn r3647. Signed-off-by: Peter Stuge <peter@stuge.se> Acked-by: Peter Stuge <peter@stuge.se>
This commit is contained in:
parent
cbfed28880
commit
23dc1df565
@ -449,6 +449,10 @@ int main(int argc, char *argv[])
|
|||||||
printf("Run flashrom -L to view the hardware supported in this flashrom version.\n");
|
printf("Run flashrom -L to view the hardware supported in this flashrom version.\n");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
if (!filename) {
|
||||||
|
printf("Error: No filename specified.\n");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
size = flashes[0]->total_size * 1024;
|
size = flashes[0]->total_size * 1024;
|
||||||
buf = (uint8_t *) calloc(size, sizeof(char));
|
buf = (uint8_t *) calloc(size, sizeof(char));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user