# HG changeset patch # User John W. Eaton # Date 1320472780 14400 # Node ID f1b023fd098d717d5095212c0bcbc4f98355552f # Parent 822f80b908660755b800fc6023b7ef4195a17c1c always initialize info and rcon in Matrix determinant methods * dMatrix.cc (Matrix::determinant): Always initialize info and rcon. * CMatrix.cc (ComplexMatrix::determinant): Likewise. * fMatrix.cc (FloatMatrix::determinant): Likewise. * fCMatrix.cc (FloatComplexMatrix::determinant): Likewise. diff --git a/liboctave/CMatrix.cc b/liboctave/CMatrix.cc --- a/liboctave/CMatrix.cc +++ b/liboctave/CMatrix.cc @@ -1571,6 +1571,9 @@ { ComplexDET retval (1.0); + info = 0; + rcon = 0.0; + octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -1599,7 +1602,6 @@ ComplexMatrix atmp = *this; Complex *tmp_data = atmp.fortran_vec (); - info = 0; double anorm = 0; if (calc_cond) anorm = xnorm (*this, 1); diff --git a/liboctave/dMatrix.cc b/liboctave/dMatrix.cc --- a/liboctave/dMatrix.cc +++ b/liboctave/dMatrix.cc @@ -1239,6 +1239,9 @@ { DET retval (1.0); + info = 0; + rcon = 0.0; + octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -1267,7 +1270,6 @@ Matrix atmp = *this; double *tmp_data = atmp.fortran_vec (); - info = 0; double anorm = 0; if (calc_cond) anorm = xnorm (*this, 1); diff --git a/liboctave/fCMatrix.cc b/liboctave/fCMatrix.cc --- a/liboctave/fCMatrix.cc +++ b/liboctave/fCMatrix.cc @@ -1567,6 +1567,9 @@ { FloatComplexDET retval (1.0); + info = 0; + rcon = 0.0; + octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -1595,7 +1598,6 @@ FloatComplexMatrix atmp = *this; FloatComplex *tmp_data = atmp.fortran_vec (); - info = 0; float anorm = 0; if (calc_cond) anorm = xnorm (*this, 1); diff --git a/liboctave/fMatrix.cc b/liboctave/fMatrix.cc --- a/liboctave/fMatrix.cc +++ b/liboctave/fMatrix.cc @@ -1239,6 +1239,9 @@ { FloatDET retval (1.0); + info = 0; + rcon = 0.0; + octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -1267,7 +1270,6 @@ FloatMatrix atmp = *this; float *tmp_data = atmp.fortran_vec (); - info = 0; float anorm = 0; if (calc_cond) anorm = xnorm (*this, 1);