Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C Programming > different result valgrind on different OS

Reply
Thread Tools

different result valgrind on different OS

 
 
fakessh @
Guest
Posts: n/a
 
      06-06-2012
hello doctor
hello honorable

I work on a small project in c.
https://raw.github.com/fakessh/openp...smtp_openssl.c
This is an smtp client with minimal authentication. I use
openssl successfully to encode base64 data are

I just did my first tests with valgrind
and I get different results on centos 5 and centos 6

this is the end of the trace of valgrind

on centos 5
==18553== LEAK SUMMARY:
==18553== definitely lost: 0 bytes in 0 blocks
==18553== indirectly lost: 0 bytes in 0 blocks
==18553== possibly lost: 36 bytes in 3 blocks
==18553== still reachable: 106,700 bytes in 2,163 blocks
==18553== suppressed: 0 bytes in 0 blocks
==18553==
==18553== For counts of detected and suppressed errors, rerun
with: -v
==18553== ERROR SUMMARY: 3 errors from 3 contexts
(suppressed: 29 from 10)


on centos 6
==8836== LEAK SUMMARY:
==8836== definitely lost: 0 bytes in 0 blocks
==8836== indirectly lost: 0 bytes in 0 blocks
==8836== possibly lost: 0 bytes in 0 blocks
==8836== still reachable: 39,320 bytes in 2,485 blocks
==8836== suppressed: 0 bytes in 0 blocks
==8836==
==8836== For counts of detected and suppressed errors, rerun
with: -v
==8836== ERROR SUMMARY: 349 errors from 6 contexts
(suppressed: 29 from 10)

there are a number of very different error and centos 5 shows
a memory leak

can you help me find the problems in my code

 
Reply With Quote
 
 
 
 
Ben Bacarisse
Guest
Posts: n/a
 
      06-06-2012
"fakessh @" <(E-Mail Removed)> writes:

> hello doctor
> hello honorable
>
> I work on a small project in c.
> https://raw.github.com/fakessh/openp...smtp_openssl.c
> This is an smtp client with minimal authentication. I use
> openssl successfully to encode base64 data are
>
> I just did my first tests with valgrind
> and I get different results on centos 5 and centos 6
>
> this is the end of the trace of valgrind
>
> on centos 5
> ==18553== LEAK SUMMARY:
> ==18553== definitely lost: 0 bytes in 0 blocks
> ==18553== indirectly lost: 0 bytes in 0 blocks
> ==18553== possibly lost: 36 bytes in 3 blocks
> ==18553== still reachable: 106,700 bytes in 2,163 blocks
> ==18553== suppressed: 0 bytes in 0 blocks
> ==18553==
> ==18553== For counts of detected and suppressed errors, rerun
> with: -v
> ==18553== ERROR SUMMARY: 3 errors from 3 contexts
> (suppressed: 29 from 10)
>
>
> on centos 6
> ==8836== LEAK SUMMARY:
> ==8836== definitely lost: 0 bytes in 0 blocks
> ==8836== indirectly lost: 0 bytes in 0 blocks
> ==8836== possibly lost: 0 bytes in 0 blocks
> ==8836== still reachable: 39,320 bytes in 2,485 blocks
> ==8836== suppressed: 0 bytes in 0 blocks
> ==8836==
> ==8836== For counts of detected and suppressed errors, rerun
> with: -v
> ==8836== ERROR SUMMARY: 349 errors from 6 contexts
> (suppressed: 29 from 10)
>
> there are a number of very different error and centos 5 shows
> a memory leak
>
> can you help me find the problems in my code


If you compile with -g (debug symbols on) valgrind will tell on exactly
what line the error occurred (and, usually, on what line the offending
memory was allocated). With such a small program, it should not be hard
to use this information to find out exactly what it wrong.

--
Ben.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
1. Ruby result: 101 seconds , 2. Java result:9.8 seconds, 3. Perl result:62 seconds Michael Tan Ruby 32 07-21-2005 03:23 PM
Valgrind says "Invalid read of size 4". What's the problem? hvaisane@cc.joensuu.fi C++ 2 02-17-2005 12:45 PM
Problems with valgrind Andreas Andersen C++ 2 01-18-2005 03:06 PM
Checking for memory leaks: valgrind versus insure++ rsina C++ 2 11-29-2004 11:04 AM
leak detected using valgrind Alexandre C++ 1 11-13-2003 07:43 AM



Advertisments