title: Is it a memory leak to push_back a pointer into a vector of pointers?
body: <p>In my class, I have a member variable <code>std::vector&lt;node*&gt; children</code></p>
  
  <p>Does the following class member function create a memory leak?</p>
  
  <pre><code>//adds a child node
  {
      node* child = new node("blah","blah","blah");
      child-&gt;Set_Parent(this);
      children.push_back(child);  //&lt;- Is this ok?
  }
  </code></pre>
  
  <p>The vector makes a copy of the pointer and I have two pointers to the same memory,
  and then the original pointer goes out of scope, right?  </p>
  
  <p>This may be simple and obvious,  but I would just like to confirm my assumption.<br>
  thanks</p>