title: Delete a node from the middle of a C++ queue
body: <p>I have a linked list with a c-style <code>ctor</code> and <code>dtor</code>.</p>
  
  <p>I just got too frustrated when this if statement decided not to test true, putting me in
  an infinite loop. I dont understand why it will never test true.</p>
  
  <p>I am trying to delete a node (the address of a class object) from my <code>LinkedList</code>.</p>
  
  <p>Maybe someone could help me out?</p>
  
  <pre><code>Node *Current = first_; // I want this to be my only Node Ptr Varaible Declaration.
  if ( NULL == first_ )
  std::cout &lt;&lt; "Cannot delete from an empty list: \n";
  
  
  while ( Current != NULL )
  {
    if ( first_-&gt;data_ == node-&gt;data_ ) 
    {
      //check to see if we are deleteing the head.
      first_ = first_-&gt;next_;
      --listLen_;
      delete Current;
      std::cout &lt;&lt; "Head Deleted!\n";
    }
    if ( Current-&gt;data_ == node-&gt;data_ ) // FOR SOME REASON this is never true?
    {
      --listLen_;
      node-&gt;data_ = NULL;
      Current     = Current-&gt;next_;
      node-&gt;data_ = Current;
    }
    else  // we must not of found it.  // else should match previous i
    {
      Current-&gt;prev_ = Current;// since we are not deleting the first node we are OK here.
      Current        = first_-&gt;next_;
  
      if ( Current-&gt;next_ == NULL ) // see if we are at the end of the list.
      {
        first_ = NULL;  
        last_  = Current-&gt;prev_;
  
      }
    }
  }
  return;
  </code></pre>