From b946950ca23d308cbd101b81311157d4643cb8bc Mon Sep 17 00:00:00 2001
From: Philippe WAUTELET <philippe.wautelet@aero.obs-mip.fr>
Date: Fri, 9 Dec 2022 11:37:42 +0100
Subject: [PATCH] Philippe 09/12/2022: flyers: keep previous NMODEL value in
 case of crash

---
 src/MNH/aircraft_balloon_evol.f90 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/MNH/aircraft_balloon_evol.f90 b/src/MNH/aircraft_balloon_evol.f90
index a246e4391..8b6383b57 100644
--- a/src/MNH/aircraft_balloon_evol.f90
+++ b/src/MNH/aircraft_balloon_evol.f90
@@ -1673,7 +1673,7 @@ CALL FIND_PROCESS_AND_MODEL_FROM_XY_POS( ZX, ZY, IRANK, IMODEL )
 
 IF ( IRANK < 1 ) THEN
   ! Flyer is outside of horizontal domain
-  TPFLYER%NMODEL    = 1 !Set to 1 because it is always a valid model (to prevent crash if NDAD(TPFLYER%NMODEL) )
+  ! TPFLYER%NMODEL !Do not change to keep a valid value
   TPFLYER%LCRASH    = .TRUE.
   TPFLYER%NCRASH    = NCRASH_OUT_HORIZ
   TPFLYER%LFLY      = .FALSE.
-- 
GitLab