diff --git a/lapack/potf2/potf2_L.c b/lapack/potf2/potf2_L.c index 8cd094ac20..dde32c587b 100644 --- a/lapack/potf2/potf2_L.c +++ b/lapack/potf2/potf2_L.c @@ -71,7 +71,7 @@ blasint CNAME(blas_arg_t *args, BLASLONG *range_m, BLASLONG *range_n, FLOAT *sa, ajj = *(aoffset + j) - DOTU_K(j, a + j, lda, a + j, lda); - if (ajj <= 0){ + if (ajj <= 0|| ajj!=ajj){ *(aoffset + j) = ajj; return j + 1; } diff --git a/lapack/potf2/potf2_U.c b/lapack/potf2/potf2_U.c index 9f908c14cc..9bfea43976 100644 --- a/lapack/potf2/potf2_U.c +++ b/lapack/potf2/potf2_U.c @@ -68,7 +68,7 @@ blasint CNAME(blas_arg_t *args, BLASLONG *range_m, BLASLONG *range_n, FLOAT *sa, ajj = *(a + j) - DOTU_K(j, a, 1, a, 1); - if (ajj <= 0){ + if (ajj <= 0|| ajj!=ajj){ *(a + j) = ajj; return j + 1; } diff --git a/lapack/potf2/zpotf2_L.c b/lapack/potf2/zpotf2_L.c index d265c5d884..dbf3ff23f6 100644 --- a/lapack/potf2/zpotf2_L.c +++ b/lapack/potf2/zpotf2_L.c @@ -72,7 +72,7 @@ blasint CNAME(blas_arg_t *args, BLASLONG *range_m, BLASLONG *range_n, FLOAT *sa, ajj = *(aoffset + j * 2) - ajj; - if (ajj <= 0){ + if (ajj <= 0|| ajj!=ajj){ *(aoffset + j * 2 + 0) = ajj; *(aoffset + j * 2 + 1) = ZERO; return j + 1; diff --git a/lapack/potf2/zpotf2_U.c b/lapack/potf2/zpotf2_U.c index 594a90ad3f..c8792eef28 100644 --- a/lapack/potf2/zpotf2_U.c +++ b/lapack/potf2/zpotf2_U.c @@ -69,7 +69,7 @@ blasint CNAME(blas_arg_t *args, BLASLONG *range_m, BLASLONG *range_n, FLOAT *sa, ajj = *(a + j * 2) - ajj; - if (ajj <= 0){ + if (ajj <= 0||ajj!=ajj){ *(a + j * 2 + 0) = ajj; *(a + j * 2 + 1) = ZERO; return j + 1;