Skip to content

Instantly share code, notes, and snippets.

@bdw
Created August 14, 2017 15:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bdw/9b0076211c6d7d80e8ec2c660ea7c6b9 to your computer and use it in GitHub Desktop.
Save bdw/9b0076211c6d7d80e8ec2c660ea7c6b9 to your computer and use it in GitHub Desktop.
off-by-one.txt
per
==81774== Invalid read of size 1
==81774== at 0x100117D91: threebyte_memmem (memmem.c:41)
==81774== by 0x100117B97: memmem (memmem.c:177)
==81774== by 0x10011878C: MVM_memmem (memmem.h:18)
==81774== by 0x1001192A7: MVM_string_index (ops.c:286)
==81774== by 0x100024AA5: MVM_interp_run (interp.c:1566)
==81774== by 0x10014307C: MVM_vm_run_file (moar.c:349)
==81774== by 0x1000014EE: main (main.c:253)
==81774== Address 0x10747bfd7 is 0 bytes after a block of size 23 alloc'd
==81774== at 0x10000A621: malloc (in /Users/bwiegmans/System/brew/Cellar/valgrind/3.13.0/lib/valgrind/vgpreload_memcheck-amd64-darwin.so)
==81774== by 0x10011DB84: MVM_malloc (alloc.h:2)
==81774== by 0x100119CB2: iterate_gi_into_string (ops.c:83)
==81774== by 0x100119BA8: MVM_string_substring (ops.c:399)
==81774== by 0x10011D2C8: MVM_string_split (ops.c:1329)
==81774== by 0x100024FC3: MVM_interp_run (interp.c:1614)
==81774== by 0x10014307C: MVM_vm_run_file (moar.c:349)
==81774== by 0x1000014EE: main (main.c:253)
==81774==
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment