warnings
authorAlexander Alekhin <alexander.alekhin@intel.com>
Tue, 15 Nov 2016 13:13:30 +0000 (16:13 +0300)
committerAlexander Alekhin <alexander.alekhin@intel.com>
Fri, 18 Nov 2016 12:31:59 +0000 (15:31 +0300)
apps/haartraining/createsamples.cpp
modules/core/src/gpumat.cpp
modules/gpu/include/opencv2/gpu/gpu.hpp

index 4d01fbd..f0a8eab 100644 (file)
 #include <ctime>
 #include <memory>
 
+// std::auto_ptr
+#if defined(__GNUC__) && __GNUC__ >= 6
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+#endif
+
 using namespace std;
 
 #include "cvhaartraining.h"
index 9669191..5065deb 100644 (file)
@@ -700,7 +700,7 @@ void cv::gpu::GpuMat::create(int _rows, int _cols, int _type)
 
         size_t esz = elemSize();
 
-        void* devPtr;
+        void* devPtr = NULL;
         gpuFuncTable()->mallocPitch(&devPtr, &step, esz * cols, rows);
 
         // Single row must be continuous
index de16982..088b524 100644 (file)
 #include "opencv2/objdetect/objdetect.hpp"
 #include "opencv2/features2d/features2d.hpp"
 
+// std::auto_ptr
+#if defined(__GNUC__) && __GNUC__ >= 6
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+#endif
+
 namespace cv { namespace gpu {
 
 //////////////////////////////// CudaMem ////////////////////////////////
@@ -2527,4 +2533,8 @@ CV_EXPORTS void calcWobbleSuppressionMaps(
 
 } // namespace cv
 
+#if defined(__GNUC__) && __GNUC__ >= 6
+#pragma GCC diagnostic pop
+#endif
+
 #endif /* __OPENCV_GPU_HPP__ */