Re: Using LD_PRELOAD wrappers to identify problem use of shared library functions

2011-03-21 Thread John Reiser
On 03/10/2011, Jakub Jelinek wrote: > And, it would be nice when you have such a library not to check just > memcpy, there are plenty of other commonly used calls which could > be warned about. > > memcpy, strcpy, strncpy, strcat, strncat, strtok, strtok_r, mempcpy, strsep, > stpcpy, stpncpy, mem

Re: Using LD_PRELOAD wrappers to identify problem use of shared library functions

2011-03-11 Thread William Cohen
On 03/11/2011 12:29 AM, John Reiser wrote: > On 03/10/2011 08:25 AM, William Cohen wrote: >> git repo at: >> >> http://fedorapeople.org/gitweb?p=wcohen/public_git/memstomp;a=summary > > Actually: git clone > git://fedorapeople.org/home/fedora/wcohen/public_git/memstomp > > The implementation has

Re: Using LD_PRELOAD wrappers to identify problem use of shared library functions

2011-03-10 Thread John Reiser
On 03/10/2011 08:25 AM, William Cohen wrote: > git repo at: > > http://fedorapeople.org/gitweb?p=wcohen/public_git/memstomp;a=summary Actually: git clone git://fedorapeople.org/home/fedora/wcohen/public_git/memstomp The implementation has some properties: 1. Not async signal safe [malloc, fpri

Re: Using LD_PRELOAD wrappers to identify problem use of shared library functions

2011-03-10 Thread John Reiser
On 03/10/2011 08:25 AM, William Cohen wrote: > I have taken the code in the mutrace package and made memstomp which looks > for the memcpy of overlapping regions. > > git repo at: > > http://fedorapeople.org/gitweb?p=wcohen/public_git/memstomp;a=summary Did anybody else run into trouble trying

Re: Using LD_PRELOAD wrappers to identify problem use of shared library functions

2011-03-10 Thread Jakub Jelinek
On Thu, Mar 10, 2011 at 11:25:38AM -0500, William Cohen wrote: > Shared library are heavily used through Linux distributions. > Unfortunately, there are cases of functions in the libraries having > undefined behavior. Rather than immediately reporting the dependence on > that undefined behavior,

Re: Using LD_PRELOAD wrappers to identify problem use of shared library functions

2011-03-10 Thread Daniel P. Berrange
On Thu, Mar 10, 2011 at 11:25:38AM -0500, William Cohen wrote: > > git repo at: > > http://fedorapeople.org/gitweb?p=wcohen/public_git/memstomp;a=summary > > A fedora scratch package RPM at: > > http://koji.fedoraproject.org/koji/taskinfo?taskID=2898613 > > > Valgrind does check the arguments