Im getting this result from Valgrind:
==24810== HEAP SUMMARY:
==24810== in use at exit: 0 bytes in 0 blocks
==24810== total heap usage: 9 allocs, 6 frees, 0 bytes allocated
==24810==
==24810== LEAK SUMMARY:
==24810== definitely lost: 0 bytes in 0 blocks
==24810== indirectly lost: 0 bytes in 0 blocks
==24810== possibly lost: 0 bytes in 0 blocks
==24810== still reachable: 0 bytes in 0 blocks
==24810== suppressed: 0 bytes in 0 blocks
It says no memory was leaked. It looks to me as a good result. But, what about these 9 allocs, 6 frees? It looks like I haven’t free’d some memory somewhere. I checked the code, and there are 3 global const pointers. Maybe they weren’t considered as errors but printed as not free’d?
Should I worry about this or should I considered the code buggless?
Thank you all.
….Just trying to understand all that ANSI C hassle with pointers and memory allocations :)))
maxim
in valgrind website http://valgrind.org/docs/manual/quick-start.html#quick-start.interpret
So for your case your program should be good.