Skip to content
Snippets Groups Projects
Closed Every _free() function should be a macro that sets the corresponding pointer to NULL.
  • View options
  • Every _free() function should be a macro that sets the corresponding pointer to NULL.

  • View options
  • Closed Issue created by Nick Mathewson

    Our tor_free() macros has saved us a bunch of trouble in the past by ensuring that once we've freed a pointer, that pointer gets set to NULL.

    Wouldn't it be cool if all of our free() calls did this? It should make our code generally less error-prone.

    As we work on legacy/trac#23847 (moved), I bet we will find it extremely helpful.

    Linked items ... 0

  • Activity

    • All activity
    • Comments only
    • History only
    • Newest first
    • Oldest first
    Loading Loading Loading Loading Loading Loading Loading Loading Loading Loading