This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Decouple "set confirm" from `from_tty'.


On 01/20/2012 11:33 AM, Joel Brobecker wrote:
>> Eventually, I figured out this was caused by having done
>> "set confirm off" before the source command.
>>
>>  (gdb) source /wrong/path/to/file.py
>>  /wrong/path/to/file.py: No such file or directory.
>>  (gdb) set confirm off
>>  (gdb) source /wrong/path/to/file.py
>>  (gdb)
>>
>> This was very surprising to me, and I assume to surprise other
>> users too.  Turns out that "set confirm off" also has the
>> side-effect of running commands with from_tty == 0, which
>> silences many things.  E.g.,
> 
> I agree this is very surprising! I'm even amazed that we did not
> realize this until now....

Yeah...

> Sounds good to me. To me, "set confirm off" means do everything
> the same except auto-answer "y" when I said to do something that
> GDB think might be questionable.

Yeah.

> No problem spotted with the patch.

Thanks.  The patch is now in, committed in two pieces.

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]