From ca48f53e5a9ac415a6554f5fdfe88719beec7245 Mon Sep 17 00:00:00 2001 From: Guillaume Horel Date: Mon, 21 Dec 2020 11:25:40 -0500 Subject: fail early --- src/lossdistrib.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/lossdistrib.c') diff --git a/src/lossdistrib.c b/src/lossdistrib.c index a9dc82c..c23cb5c 100644 --- a/src/lossdistrib.c +++ b/src/lossdistrib.c @@ -394,6 +394,9 @@ void recovdist(const double *dp, const double *pp, const int *n, const double *w } double shockprob(double p, double rho, double Z, int give_log){ + if(rho > 1.) { + abort(); + } if(rho == 1.) { if( give_log ) { abort(); -- cgit v1.2.3-70-g09d2