Re: [PATCH] Add getenv.so for catching invalid getenv() use via LD_PRELOAD

2013-01-07 Thread David Michael
Hi, On Sat, Jan 5, 2013 at 3:55 AM, Nguyễn Thái Ngọc Duy pclo...@gmail.com wrote: Perhaps this will help the getenv bug hunting (I assume we do the hunting on Linux platform only). So far it catches this and is stuck at getenv in git_pager(). For the record: I have been testing a macro

[PATCH] Add getenv.so for catching invalid getenv() use via LD_PRELOAD

2013-01-05 Thread Nguyễn Thái Ngọc Duy
Signed-off-by: Nguyễn Thái Ngọc Duy pclo...@gmail.com --- Perhaps this will help the getenv bug hunting (I assume we do the hunting on Linux platform only). So far it catches this and is stuck at getenv in git_pager(). diff --git a/exec_cmd.c b/exec_cmd.c index 125fa6f..d8be5ce 100644

Re: [PATCH] Add getenv.so for catching invalid getenv() use via LD_PRELOAD

2013-01-05 Thread Matt Kraai
On Sat, Jan 05, 2013 at 03:55:46PM +0700, Nguyễn Thái Ngọc Duy wrote: Perhaps this will help the getenv bug hunting (I assume we do the hunting on Linux platform only). So far it catches this and is stuck at getenv in git_pager(). It seems like a static analysis tool might be able to detect

Re: [PATCH] Add getenv.so for catching invalid getenv() use via LD_PRELOAD

2013-01-05 Thread Duy Nguyen
On Sat, Jan 5, 2013 at 5:39 PM, Matt Kraai kr...@ftbfs.org wrote: On Sat, Jan 05, 2013 at 03:55:46PM +0700, Nguyễn Thái Ngọc Duy wrote: Perhaps this will help the getenv bug hunting (I assume we do the hunting on Linux platform only). So far it catches this and is stuck at getenv in

Re: [PATCH] Add getenv.so for catching invalid getenv() use via LD_PRELOAD

2013-01-05 Thread Jonathan Nieder
Nguyễn Thái Ngọc Duy wrote: Signed-off-by: Nguyễn Thái Ngọc Duy pclo...@gmail.com --- Perhaps this will help the getenv bug hunting Even if no one decides to do the getenv hunting (I haven't decided yet whether it's worth the trouble, though patches like the setup_path() one that make string