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: [patch] New set auto-load-local-gdbinit + disable it by default


On Tue, 17 Jan 2012 21:21:42 +0100, Pedro Alves wrote:
> Having to request a safe mode with an extra flag is a flawed design, IMO.
> New, and non-aware-of-the-issues-implied (read, most) users, will just
> not know about it, and will therefore not use it.

I agree with it.  I am thinking about it for more days already.  But I have
not found a way out.

The problem is to differentiate these two cases:
(a) as regular user:
	$ tar xzf foreign-crash.tar.gz; cd foreign-crash
	$ gdb crashprog crashcore # *-gdb.py files lay here around
	 - You are 0wn3d!
(b) as regular user:
	$ cd my/great/project; make
	# gdb myprog-using-local-new-gdb.py-pretty-printers

If we want to fix (a) by default we have to regress (b) in the default case.

The second question would be which directories are safe and which are not but
that can be solved by some configuration variable and site-adjustable value.


Thanks,
Jan


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