Skip to content

Instantly share code, notes, and snippets.

@larryhou
Created September 26, 2023 07:40
Show Gist options
  • Save larryhou/96c337f1e04d1be22d04d93c2627c582 to your computer and use it in GitHub Desktop.
Save larryhou/96c337f1e04d1be22d04d93c2627c582 to your computer and use it in GitHub Desktop.
Kill tcp connection without killing parent process
lsof -i tcp:[PORT]
lldb -p [PROCESS_ID]
$ call (int)close([FILE_ID])

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment