title: common causes for std::list container filled with errors
body: <p>I am having trouble in a multithreaded environment. I have a correctly "Multiple Read-Single Write"-Lock set up environment, that modifies a <code>std::list</code>. 
  My problem now is, that i recieve an "list iterator not dereferencable"-exception and Visual is only displaying this if I inspect it:</p>
  
  <p><a href="https://i.stack.imgur.com/B2nmK.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/B2nmK.png" alt="data shows only (error) in visual debugger"></a></p>
  
  <p>The first item in the list has the value "0xcdcdcdcd". </p>
  
  <p>What could be the cause? I would love to provide you more details, but I have no idea where to start, it already costed me several days of debugging into it, but if the code runs with breakpoints, this does not happen. </p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>I have reduced it to now to a much more simple problem (sadly still not able to reduce it to a small non-working example). It is now run only in a single threaded environment - so no more multithreading issues can apply. </p>
  
  <p>The list is filled with aroud 5000 elements, I make a call to <code>data.resize(100)</code> and it crashes - having removed ~3500 elements. 
  Every element is always handled exactly the same, they all are contained in <code>shared_ptr&lt;&gt;</code></p>
  
  <p>I do not save any iterators, that may get invalid, it just crashes by having by having erased a random element in the list. 
  I have no clue where to start.</p>