Messages in this thread | | | Subject | Re: [PATCH 04/12] perf inject: Add facility to do in place update | From | Adrian Hunter <> | Date | Thu, 29 Apr 2021 19:22:54 +0300 |
| |
On 29/04/21 7:00 pm, Andi Kleen wrote: >> + if (!data.force && !inject.in_place_update_dry_run) { >> + char reply[10]; >> + >> + printf("The input file will be updated in place. OK? (y/n) "); >> + if (!fgets(reply, sizeof(reply), stdin) || strcmp(reply, "y\n")) { > > Interactive questions could break lots of scripting. > > Just error out in this case and require the option. >
If it is used with --force (or -f) then there is no prompt.
| |