Open
Conversation
Author
|
Evidence (thanks to villoc ): The program used was: void *ptr1 = malloc(29);
free(ptr1);
malloc(1);
malloc(5);
int *ptr2 = malloc(3);
free(ptr2);
malloc(4);And executed this way: $ patch -p1 < exersise_2_split.patch
patching file malloc.c
$ make
$ setarch x86_64 -R ltrace ./wrapper ./test-0 |& tail +6 | tee ltrace.out
malloc(29) = 0x555555559018
free(0x555555559018) = <void>
malloc(1) = 0x555555559018
malloc(5) = 0x55555555904d
malloc(3) = 0x555555559031
free(0x555555559031) = <void>
malloc(4) = 0x555555559031
+++ exited (status 0) +++
$ cat ltrace.out | /tmp/villoc/villoc.py --chronological --header=24 --round=1 --minsz=0 - - > /tmp/out.html |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

We could also create the rest of the solutions in the same format (as a diff from the original) to avoid repeated code.
Offtopic: Thank you so much for the tutorial. The code is so beautiful that it demonstrates that C is the best language for this type of tasks.