| 1 |
From 9147d0955358212a13e336b97e2ebe50fa069ab2 Mon Sep 17 00:00:00 2001 |
| 2 |
From: nicknide <[email protected]> |
| 3 |
Date: Mon, 24 Jul 2023 04:22:37 +0800 |
| 4 |
Subject: [PATCH 05/36] fix invalid assert dtAssert(npath < m_maxPath) (#619) |
| 5 |
|
| 6 |
--- |
| 7 |
DetourCrowd/Source/DetourPathCorridor.cpp | 2 +- |
| 8 |
1 file changed, 1 insertion(+), 1 deletion(-) |
| 9 |
|
| 10 |
diff --git a/DetourCrowd/Source/DetourPathCorridor.cpp b/DetourCrowd/Source/DetourPathCorridor.cpp |
| 11 |
index e54d463..bddea5a 100644 |
| 12 |
--- a/DetourCrowd/Source/DetourPathCorridor.cpp |
| 13 |
+++ b/DetourCrowd/Source/DetourPathCorridor.cpp |
| 14 |
@@ -512,7 +512,7 @@ void dtPathCorridor::setCorridor(const float* target, const dtPolyRef* path, con |
| 15 |
{ |
| 16 |
dtAssert(m_path); |
| 17 |
dtAssert(npath > 0); |
| 18 |
- dtAssert(npath < m_maxPath); |
| 19 |
+ dtAssert(npath <= m_maxPath); |
| 20 |
|
| 21 |
dtVcopy(m_target, target); |
| 22 |
memcpy(m_path, path, sizeof(dtPolyRef)*npath); |
| 23 |
-- |
| 24 |
2.43.0 |
| 25 |
|