title: Memory deallocation question
body: <p>I just want to make sure that I'm properly deallocating memory in my program...</p>
  
  <p>I build a dynamically allocated 2D array in one function ( build_proc_table() ) and return the array to where the function was called ( main() ). The array is stored in a variable in main() and I made a "destructor" function that deallocates the memory, but the destructor is called in main() as well, not where the memory for the array was originally allocated at ( in build_proc_table() )...</p>
  
  <p>I don't get any errors or anything ( compile time or run time ) and the program functions exactly as I wan't it to, I just want to make sure that I'm not causing a memory leak.</p>