Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ╰─➤ valgrind ./main 130 ↵
- ==21012== Memcheck, a memory error detector
- ==21012== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
- ==21012== Using Valgrind-3.14.0 and LibVEX; rerun with -h for copyright info
- ==21012== Command: ./main
- ==21012==
- O pisteet
- Tiedoston nimi on: pisteet
- Oppilas 111111 lisätty listaan
- Oppilas 234567 lisätty listaan
- Virheellinen syöte
- L
- ==21012== Invalid read of size 8
- ==21012== at 0x109817: sort (main.c:99)
- ==21012== by 0x10A323: main (main.c:348)
- ==21012== Address 0x4a51048 is 8 bytes inside a block of size 48 free'd
- ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
- ==21012== by 0x109A8C: lataa (main.c:138)
- ==21012== by 0x10A469: main (main.c:375)
- ==21012== Block was alloc'd at
- ==21012== at 0x483777F: malloc (vg_replace_malloc.c:299)
- ==21012== by 0x10A1D7: main (main.c:312)
- ==21012==
- ==21012== Invalid read of size 8
- ==21012== at 0x109419: print_lista (main.c:37)
- ==21012== by 0x10A332: main (main.c:349)
- ==21012== Address 0x4a51048 is 8 bytes inside a block of size 48 free'd
- ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
- ==21012== by 0x109A8C: lataa (main.c:138)
- ==21012== by 0x10A469: main (main.c:375)
- ==21012== Block was alloc'd at
- ==21012== at 0x483777F: malloc (vg_replace_malloc.c:299)
- ==21012== by 0x10A1D7: main (main.c:312)
- ==21012==
- Lista on tyhjä
- Q
- ==21012== Invalid read of size 8
- ==21012== at 0x10A504: main (main.c:383)
- ==21012== Address 0x4a51048 is 8 bytes inside a block of size 48 free'd
- ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
- ==21012== by 0x109A8C: lataa (main.c:138)
- ==21012== by 0x10A469: main (main.c:375)
- ==21012== Block was alloc'd at
- ==21012== at 0x483777F: malloc (vg_replace_malloc.c:299)
- ==21012== by 0x10A1D7: main (main.c:312)
- ==21012==
- ==21012== Invalid free() / delete / delete[] / realloc()
- ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
- ==21012== by 0x10A51B: main (main.c:387)
- ==21012== Address 0x4a51040 is 0 bytes inside a block of size 48 free'd
- ==21012== at 0x48389AB: free (vg_replace_malloc.c:530)
- ==21012== by 0x109A8C: lataa (main.c:138)
- ==21012== by 0x10A469: main (main.c:375)
- ==21012== Block was alloc'd at
- ==21012== at 0x483777F: malloc (vg_replace_malloc.c:299)
- ==21012== by 0x10A1D7: main (main.c:312)
- ==21012==
- Poistutaan ohjelmasta==21012==
- ==21012== HEAP SUMMARY:
- ==21012== in use at exit: 173 bytes in 3 blocks
- ==21012== total heap usage: 10 allocs, 8 frees, 7,061 bytes allocated
- ==21012==
- ==21012== LEAK SUMMARY:
- ==21012== definitely lost: 144 bytes in 1 blocks
- ==21012== indirectly lost: 29 bytes in 2 blocks
- ==21012== possibly lost: 0 bytes in 0 blocks
- ==21012== still reachable: 0 bytes in 0 blocks
- ==21012== suppressed: 0 bytes in 0 blocks
- ==21012== Rerun with --leak-check=full to see details of leaked memory
- ==21012==
- ==21012== For counts of detected and suppressed errors, rerun with: -v
- ==21012== ERROR SUMMARY: 4 errors from 4 contexts (suppressed: 0 from 0)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement