Advertisement
mmaruseacph2

Untitled

Mar 2nd, 2012
29
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.34 KB | None | 0 0
  1. mihai@keldon:/data/prg/prgcts/pilgrimgray_2012/2.dogson/fanton$ valgrind ./Dogson < ../test.txt
  2. ==11948== Memcheck, a memory error detector
  3. ==11948== Copyright (C) 2002-2011, and GNU GPL'd, by Julian Seward et al.
  4. ==11948== Using Valgrind-3.7.0 and LibVEX; rerun with -h for copyright info
  5. ==11948== Command: ./Dogson
  6. ==11948==
  7. >Take a NAP after you EAT
  8. <
  9. ==11948== Use of uninitialised value of size 8
  10. ==11948== at 0x400F5B: mytolower (in /data/prg/prgcts/pilgrimgray_2012/2.dogson/fanton/Dogson)
  11. ==11948== by 0x40109F: main (in /data/prg/prgcts/pilgrimgray_2012/2.dogson/fanton/Dogson)
  12. ==11948==
  13. ==11948== Invalid read of size 1
  14. ==11948== at 0x400F5B: mytolower (in /data/prg/prgcts/pilgrimgray_2012/2.dogson/fanton/Dogson)
  15. ==11948== by 0x40109F: main (in /data/prg/prgcts/pilgrimgray_2012/2.dogson/fanton/Dogson)
  16. ==11948== Address 0x0 is not stack'd, malloc'd or (recently) free'd
  17. ==11948==
  18. ==11948==
  19. ==11948== Process terminating with default action of signal 11 (SIGSEGV)
  20. ==11948== Access not within mapped region at address 0x0
  21. ==11948== at 0x400F5B: mytolower (in /data/prg/prgcts/pilgrimgray_2012/2.dogson/fanton/Dogson)
  22. ==11948== by 0x40109F: main (in /data/prg/prgcts/pilgrimgray_2012/2.dogson/fanton/Dogson)
  23. ==11948== If you believe this happened as a result of a stack
  24. ==11948== overflow in your program's main thread (unlikely but
  25. ==11948== possible), you can try to increase the size of the
  26. ==11948== main thread stack using the --main-stacksize= flag.
  27. ==11948== The main thread stack size used in this run was 8388608.
  28. ==11948==
  29. ==11948== HEAP SUMMARY:
  30. ==11948== in use at exit: 8,000,004 bytes in 2 blocks
  31. ==11948== total heap usage: 2 allocs, 0 frees, 8,000,004 bytes allocated
  32. ==11948==
  33. ==11948== LEAK SUMMARY:
  34. ==11948== definitely lost: 0 bytes in 0 blocks
  35. ==11948== indirectly lost: 0 bytes in 0 blocks
  36. ==11948== possibly lost: 0 bytes in 0 blocks
  37. ==11948== still reachable: 8,000,004 bytes in 2 blocks
  38. ==11948== suppressed: 0 bytes in 0 blocks
  39. ==11948== Rerun with --leak-check=full to see details of leaked memory
  40. ==11948==
  41. ==11948== For counts of detected and suppressed errors, rerun with: -v
  42. ==11948== Use --track-origins=yes to see where uninitialised values come from
  43. ==11948== ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 2 from 2)
  44. Segmentation fault
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement