Advertisement
Guest User

Untitled

a guest
Apr 18th, 2019
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.10 KB | None | 0 0
  1. ╰─➤ valgrind ./main 130 ↵
  2. ==21012== Memcheck, a memory error detector
  3. ==21012== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
  4. ==21012== Using Valgrind-3.14.0 and LibVEX; rerun with -h for copyright info
  5. ==21012== Command: ./main
  6. ==21012==
  7. O pisteet
  8. Tiedoston nimi on: pisteet
  9. Oppilas 111111 lisätty listaan
  10. Oppilas 234567 lisätty listaan
  11.  
  12. Virheellinen syöte
  13. L
  14. ==21012== Invalid read of size 8
  15. ==21012== at 0x109817: sort (main.c:99)
  16. ==21012== by 0x10A323: main (main.c:348)
  17. ==21012== Address 0x4a51048 is 8 bytes inside a block of size 48 free'd
  18. ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
  19. ==21012== by 0x109A8C: lataa (main.c:138)
  20. ==21012== by 0x10A469: main (main.c:375)
  21. ==21012== Block was alloc'd at
  22. ==21012== at 0x483777F: malloc (vg_replace_malloc.c:299)
  23. ==21012== by 0x10A1D7: main (main.c:312)
  24. ==21012==
  25. ==21012== Invalid read of size 8
  26. ==21012== at 0x109419: print_lista (main.c:37)
  27. ==21012== by 0x10A332: main (main.c:349)
  28. ==21012== Address 0x4a51048 is 8 bytes inside a block of size 48 free'd
  29. ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
  30. ==21012== by 0x109A8C: lataa (main.c:138)
  31. ==21012== by 0x10A469: main (main.c:375)
  32. ==21012== Block was alloc'd at
  33. ==21012== at 0x483777F: malloc (vg_replace_malloc.c:299)
  34. ==21012== by 0x10A1D7: main (main.c:312)
  35. ==21012==
  36. Lista on tyhjä
  37. Q
  38. ==21012== Invalid read of size 8
  39. ==21012== at 0x10A504: main (main.c:383)
  40. ==21012== Address 0x4a51048 is 8 bytes inside a block of size 48 free'd
  41. ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
  42. ==21012== by 0x109A8C: lataa (main.c:138)
  43. ==21012== by 0x10A469: main (main.c:375)
  44. ==21012== Block was alloc'd at
  45. ==21012== at 0x483777F: malloc (vg_replace_malloc.c:299)
  46. ==21012== by 0x10A1D7: main (main.c:312)
  47. ==21012==
  48. ==21012== Invalid free() / delete / delete[] / realloc()
  49. ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
  50. ==21012== by 0x10A51B: main (main.c:387)
  51. ==21012== Address 0x4a51040 is 0 bytes inside a block of size 48 free'd
  52. ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
  53. ==21012== by 0x109A8C: lataa (main.c:138)
  54. ==21012== by 0x10A469: main (main.c:375)
  55. ==21012== Block was alloc'd at
  56. ==21012== at 0x483777F: malloc (vg_replace_malloc.c:299)
  57. ==21012== by 0x10A1D7: main (main.c:312)
  58. ==21012==
  59. Poistutaan ohjelmasta==21012==
  60. ==21012== HEAP SUMMARY:
  61. ==21012== in use at exit: 173 bytes in 3 blocks
  62. ==21012== total heap usage: 10 allocs, 8 frees, 7,061 bytes allocated
  63. ==21012==
  64. ==21012== LEAK SUMMARY:
  65. ==21012== definitely lost: 144 bytes in 1 blocks
  66. ==21012== indirectly lost: 29 bytes in 2 blocks
  67. ==21012== possibly lost: 0 bytes in 0 blocks
  68. ==21012== still reachable: 0 bytes in 0 blocks
  69. ==21012== suppressed: 0 bytes in 0 blocks
  70. ==21012== Rerun with --leak-check=full to see details of leaked memory
  71. ==21012==
  72. ==21012== For counts of detected and suppressed errors, rerun with: -v
  73. ==21012== ERROR SUMMARY: 4 errors from 4 contexts (suppressed: 0 from 0)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement