mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-05-02 00:34:14 +08:00
Prevent crash in CompleteOrthogonalDecomposition if object was default constructed.
This commit is contained in:
parent
50968a0a3e
commit
a3256d78d8
@ -397,6 +397,10 @@ CompleteOrthogonalDecomposition<MatrixType>& CompleteOrthogonalDecomposition<
|
|||||||
|
|
||||||
const Index rank = m_cpqr.rank();
|
const Index rank = m_cpqr.rank();
|
||||||
const Index cols = matrix.cols();
|
const Index cols = matrix.cols();
|
||||||
|
const Index rows = matrix.rows();
|
||||||
|
m_zCoeffs.resize((std::min)(rows, cols));
|
||||||
|
m_temp.resize(cols);
|
||||||
|
|
||||||
if (rank < cols) {
|
if (rank < cols) {
|
||||||
// We have reduced the (permuted) matrix to the form
|
// We have reduced the (permuted) matrix to the form
|
||||||
// [R11 R12]
|
// [R11 R12]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user