Prompt user before doing anything
This commit is contained in:
parent
21f2420d42
commit
5277b78fd3
1 changed files with 6 additions and 0 deletions
|
|
@ -242,6 +242,12 @@ int main(int argc, char *argv[]) {
|
|||
|
||||
printf("Writing %s to %s\n", wjob.filename, wjob.dev_name);
|
||||
|
||||
printf("Is this okay? (y/n): ");
|
||||
fflush(stdout);
|
||||
if ('y' != getchar()) {
|
||||
exit(0);
|
||||
}
|
||||
|
||||
wjob.buffer = malloc(BLOCKSIZE);
|
||||
wjob.buffer2 = malloc(BLOCKSIZE);
|
||||
assert(wjob.buffer);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue