Skip to content

Instantly share code, notes, and snippets.

@drrost
Created April 21, 2020 15:31
Show Gist options
  • Save drrost/5521bfcac4cd054e9ca269fc5d6e5b85 to your computer and use it in GitHub Desktop.
Save drrost/5521bfcac4cd054e9ca269fc5d6e5b85 to your computer and use it in GitHub Desktop.
# Comile the leaker
clang leaker.c -o leaker
# Run leaks detecting tool
leaks -atExit -- ./leaker | grep LEAK:
# Optional
cd /usr/local/lib
sudo ln -s /Applications/Xcode.app/Contents/Developer/usr/lib/libLeaksAtExit.dylib
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment