different result valgrind on different OS

Discussion in 'C Programming' started by fakessh @, Jun 6, 2012.

  1. fakessh @

    fakessh @ Guest

    hello doctor
    hello honorable

    I work on a small project in c.
    https://raw.github.com/fakessh/openprojectssl/master/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
    fakessh @, Jun 6, 2012
    #1
    1. Advertising

  2. "fakessh @" <> writes:

    > hello doctor
    > hello honorable
    >
    > I work on a small project in c.
    > https://raw.github.com/fakessh/openprojectssl/master/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.
    Ben Bacarisse, Jun 7, 2012
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Alexandre

    leak detected using valgrind

    Alexandre, Nov 13, 2003, in forum: C++
    Replies:
    1
    Views:
    311
    Gianni Mariani
    Nov 13, 2003
  2. rsina
    Replies:
    2
    Views:
    1,044
    ettipmoez
    Nov 29, 2004
  3. Andreas Andersen

    Problems with valgrind

    Andreas Andersen, Jan 18, 2005, in forum: C++
    Replies:
    2
    Views:
    320
    Gernot Frisch
    Jan 18, 2005
  4. Replies:
    2
    Views:
    33,996
    Victor Bazarov
    Feb 17, 2005
  5. Michael Tan
    Replies:
    32
    Views:
    930
    Ara.T.Howard
    Jul 21, 2005
Loading...

Share This Page