From 1fec29919aa92b151582473a9743c38bf624181f Mon Sep 17 00:00:00 2001 From: Atsushi Watanabe Date: Mon, 22 Apr 2024 13:09:36 +0900 Subject: [PATCH] Fix parameter validation --- src/param.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/param.c b/src/param.c index cddec66..54bc7ba 100644 --- a/src/param.c +++ b/src/param.c @@ -942,7 +942,7 @@ int set_paramptr(FILE* paramfile) if (g_P_set[YP_PARAM_MAX_TIME_JUMP][0]) { - if (g_P_set[YP_PARAM_MAX_TIME_JUMP][0] <= 0) + if (g_P[YP_PARAM_MAX_TIME_JUMP][0] <= 0) { yprintf(OUTPUT_LV_ERROR, "ERROR: MAX_TIME_JUMP must be > 0.0.\n"); param_error = 1; @@ -954,7 +954,7 @@ int set_paramptr(FILE* paramfile) } if (g_P_set[YP_PARAM_MAX_TIME_JUMP_NEG][0]) { - if (g_P_set[YP_PARAM_MAX_TIME_JUMP_NEG][0] <= 0) + if (g_P[YP_PARAM_MAX_TIME_JUMP_NEG][0] <= 0) { yprintf(OUTPUT_LV_ERROR, "ERROR: -MAX_TIME_JUMP must be > 0.0.\n"); param_error = 1;