title: Debug assertion failed opencv xmemory0 C++
body: <p>I try to run the code from <a href="http://docs.opencv.org/3.1.0/d4/d94/tutorial_camera_calibration.html" rel="nofollow">calibration</a>, and i'm stuck with this error:</p>
  
  <pre><code>Debug Assertion Failed!
  
  Program:
  C:\Users\openCV\Desktop\Git\AzTest\Debug\AzTest.exe
  File: c:\program files (x86)\microsoft visual studio 14.0\vc\include\xmemory0
  Line: 94
  
  Expression: "_Count &lt;= (size_t)(-1) / _Sz" &amp;&amp; 0
  
  For information on how your program can cause an assertion failure, see the Visual C++ documentation on asserts.
  
  (Press Retry to debug the application)
  </code></pre>
  
  <p>To be honest I don't know what else should I do, or why is this error happening.</p>
  
  <p>What is to be noted is that the code used to <strong>work</strong> on the <strong>same</strong> PC.</p>
  
  <p>I've modified the code (when it worked, and it worked after I done the changes), code can be found <a href="https://link.removed" rel="nofollow">here</a> (The project is there, also it is configured for having the <code>OpenCV</code> directory on <code>C:\opencv</code>.</p>