title: Segfault from Opencv Mat::create
body: <p>I am getting a Segmentation fault from the following call to Mat::Create</p>
  
  <pre><code>void PoissonBlend::blend(Mat&amp; src, Mat&amp; dst, Mat&amp; mask, Mat&amp; out){
  
    Mat outer(mask.rows, mask.cols, CV_8U);
  </code></pre>
  
  <p>When I run my program in gdb I can see that both rows and cols are valid, and I have tried several different data types, but no matter what I get a Segfault on this line. </p>
  
  <p>My program defines several other Mats in main(), before the call to blend, and all of them work perfectly fine.  Has anyone else ever run into this before?  This error is driving me crazy, I cant find any difference between this call to create and any of the others in my program, yet this one fails every time.</p>
  
  <p>My gdb output is:</p>
  
  <pre><code>Program received signal SIGSEGV, Segmentation fault.
  _int_malloc (av=0x7ffff6fbe740 &lt;main_arena&gt;, bytes=307228) at malloc.c:3879
  
  
  #0  _int_malloc (av=0x7ffff6fbe740 &lt;main_arena&gt;, bytes=307228) at malloc.c:3879
  #1  0x00007ffff6c88fc5 in __GI___libc_malloc (bytes=307228) at malloc.c:2924
  #2  0x00007ffff791594d in cv::fastMalloc(unsigned long) () from /usr/lib/libopencv_core.so.2.3
  #3  0x00007ffff78884bc in cv::Mat::create(int, int const*, int) () from /usr/lib/libopencv_core.so.2.3
  #4  0x00000000004243da in cv::Mat::create (this=0x7fffffffdab0, _rows=480, _cols=640, _type=0) at /usr/include/opencv2/core/mat.hpp:368
  #5  0x0000000000427608 in cv::Mat::Mat (this=0x7fffffffdab0, _rows=480, _cols=640, _type=0) at /usr/include/opencv2/core/mat.hpp:68
  #6  0x00000000004255a7 in PoissonBlend::blend (this=0x7fffffffdd13, src=..., dst=..., mask=..., out=...)
   at /home/adam/WorkingCode/rasc/trunk/src/Poisson.cpp:95
  #7  0x0000000000423eb2 in main () at    /home/adam/WorkingCode/rasc/trunk/src/PoissonTest.cpp:45
  </code></pre>