GAPI: fix uninitialized variables in Fluid
authorAnton Potapov <anton.potapov@intel.com>
Mon, 25 May 2020 08:59:28 +0000 (11:59 +0300)
committerAnton Potapov <anton.potapov@intel.com>
Mon, 25 May 2020 08:59:28 +0000 (11:59 +0300)
modules/gapi/include/opencv2/gapi/fluid/gfluidbuffer.hpp
modules/gapi/src/backends/fluid/gfluidbuffer_priv.hpp

index de16eb0..8130e2b 100644 (file)
@@ -87,7 +87,7 @@ public:
 
 private:
     std::unique_ptr<Priv> m_priv;
-    const Cache* m_cache;
+    const Cache* m_cache = nullptr;
 };
 
 class GAPI_EXPORTS Buffer
index d20d280..d6fdc0e 100644 (file)
@@ -245,7 +245,7 @@ class GAPI_EXPORTS Buffer::Priv
 
     // Coordinate starting from which this buffer is assumed
     // to be read (with border not being taken into account)
-    int m_readStart;
+    int m_readStart = 0;
     cv::Rect m_roi;
 
     friend void debugBufferPriv(const Buffer& p, std::ostream &os);