Unless your program is in a directory specified in your $PATH, you are
valgrinding the /bin/test utility.
The right command to invoke Valgrind is:
valgrind --tool=memcheck ./test
On Tue, Apr 13, 2010 at 11:22 PM, ajit gunge <peacepan...@yahoo.com> wrote:
> Hi All,
> I am trying to run the sample program on RHEL given at
> http://www.valgrind.org/docs/manual/mc-manual.html under section 4.2.2.
> now this should give me error mentioned in the section
> as to surce file with line numbers but when I am running the same program I
> dont get the line number is source file.
>
> This is the output
>
>
> [r...@kalpana tests]# valgrind --tool=memcheck test
> ==30057== Memcheck, a memory error detector
> ==30057== Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et al.
> ==30057== Using Valgrind-3.5.0 and LibVEX; rerun with -h for copyright info
> ==30057== Command: test
> ==30057==
> ==30057==
> ==30057== HEAP SUMMARY:
> ==30057== in use at exit: 0 bytes in 0 blocks
> ==30057== total heap usage: 2 allocs, 2 frees, 36 bytes allocated
> ==30057==
> ==30057== All heap blocks were freed -- no leaks are possible
> ==30057==
> ==30057== For counts of detected and suppressed errors, rerun with: -v
> ==30057== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 13 from 8)
>
>
> Please let me know why am I not getting the error along with the line
> numbers.
>
> Regards,
> Ajit
>
>
>
> ------------------------------------------------------------------------------
> Download IntelĀ® Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> Valgrind-users mailing list
> Valgrind-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/valgrind-users
>
>
--
Alexander Potapenko
Software Engineer
Google Moscow
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Valgrind-users mailing list
Valgrind-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/valgrind-users