Skip to content

Commit d45fa9e

Browse files
committed
??
1 parent 92a7a9a commit d45fa9e

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/model.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2875,15 +2875,15 @@ void Model::fdwdp(realtype const t, realtype const* x, bool include_static) {
28752875
}
28762876

28772877
void Model::fdwdx(realtype const t, realtype const* x, bool include_static) {
2878-
if (!nw || !nx_solver)
2878+
if (!nw)
28792879
return;
28802880

28812881
fw(t, x, include_static);
28822882

28832883
derived_state_.dwdx_.zero();
28842884
if (pythonGenerated) {
28852885
auto dwdx_hierarchical_0 = derived_state_.dwdx_hierarchical_.at(0);
2886-
if (!dwdx_hierarchical_0.capacity())
2886+
if (!dwdx_hierarchical_0.data() || !dwdx_hierarchical_0.capacity())
28872887
return;
28882888

28892889
fdwdw(t, x, include_static);

0 commit comments

Comments
 (0)