Browse Source

Disable VS warning C6293, as the unsigned overflow trick used in reverse iteration is intentional. Added missing DebugNew.h includes. Closes #832.

Lasse Öörni 10 years ago
parent
commit
3dcab4c039

+ 4 - 0
Source/Urho3D/Audio/Audio.cpp

@@ -36,6 +36,10 @@
 
 #include "../DebugNew.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 

+ 4 - 0
Source/Urho3D/Container/Str.cpp

@@ -28,6 +28,10 @@
 
 #include "../DebugNew.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 

+ 9 - 0
Source/Urho3D/Container/Vector.h

@@ -28,6 +28,11 @@
 #include <cstring>
 #include <new>
 
+#ifdef _MSC_VER
+#pragma warning(push)
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 
@@ -948,3 +953,7 @@ template <class T> typename Urho3D::PODVector<T>::Iterator begin(Urho3D::PODVect
 template <class T> typename Urho3D::PODVector<T>::Iterator end(Urho3D::PODVector<T>& v) { return v.End(); }
 
 }
+
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif

+ 4 - 0
Source/Urho3D/Graphics/DecalSet.cpp

@@ -42,6 +42,10 @@
 
 #include "../DebugNew.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 

+ 4 - 0
Source/Urho3D/Graphics/Drawable.cpp

@@ -35,6 +35,10 @@
 
 #include "../DebugNew.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 

+ 4 - 0
Source/Urho3D/Graphics/RenderPath.cpp

@@ -30,6 +30,10 @@
 
 #include "../DebugNew.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 

+ 4 - 0
Source/Urho3D/Graphics/Renderer.cpp

@@ -50,6 +50,10 @@
 
 #include "../DebugNew.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/AreaAllocator.cpp

@@ -24,6 +24,8 @@
 
 #include "../Math/AreaAllocator.h"
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/BoundingBox.cpp

@@ -25,6 +25,8 @@
 #include "../Math/Frustum.h"
 #include "../Math/Polyhedron.h"
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/Color.cpp

@@ -26,6 +26,8 @@
 
 #include <cstdio>
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/Frustum.cpp

@@ -24,6 +24,8 @@
 
 #include "../Math/Frustum.h"
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/Plane.cpp

@@ -24,6 +24,8 @@
 
 #include "../Math/Plane.h"
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 6 - 0
Source/Urho3D/Math/Polyhedron.cpp

@@ -25,6 +25,12 @@
 #include "../Math/Frustum.h"
 #include "../Math/Polyhedron.h"
 
+#include "../DebugNew.h"
+
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/Quaternion.cpp

@@ -26,6 +26,8 @@
 
 #include <cstdio>
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/Random.cpp

@@ -24,6 +24,8 @@
 
 #include "../Math/Random.h"
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/Ray.cpp

@@ -26,6 +26,8 @@
 #include "../Math/Frustum.h"
 #include "../Math/Ray.h"
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/Rect.cpp

@@ -26,6 +26,8 @@
 
 #include <cstdio>
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 2 - 0
Source/Urho3D/Math/Sphere.cpp

@@ -25,6 +25,8 @@
 #include "../Math/Frustum.h"
 #include "../Math/Polyhedron.h"
 
+#include "../DebugNew.h"
+
 namespace Urho3D
 {
 

+ 4 - 0
Source/Urho3D/Scene/Component.cpp

@@ -30,6 +30,10 @@
 
 #include "../DebugNew.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {
 

+ 4 - 0
Source/Urho3D/Scene/Node.cpp

@@ -37,6 +37,10 @@
 
 #include "../DebugNew.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable:6293)
+#endif
+
 namespace Urho3D
 {