title: Will my code cause memory leakage?
body: <p>I have this for loop that iterates through a vector.
  Then it checks if the given name equals the name of the model.</p>
  
  <p>Finally it creates a pointer and returns it. Now my question is if there is going to be any memory leak if i don't delete the pointer?</p>
  
  <pre><code>Model3D* ModelMemory::GetModel(char* name)
  {
     for (std::vector&lt;Model3D*&gt;::reverse_iterator it = mModels-&gt;rbegin();it != mModel-&gt;rend();it++)
      {
          Model3D *model = *it;
          if (model-&gt;GetName() == name)
          {
               return model;
          }
      }
  }
  </code></pre>
  
  <p>Thanks for your help!</p>
  
  <p>--EDIT--</p>
  
  <p>So my goal here is to store all my 3d models (stored in Model3D classes) in a vector,
  so that i can retrieve it later using the name of the Model3D.
  Is there maybe a better way to do this? Because it seems like my way is not really good programming...</p>