Commit ba5ade8
authored
Fix potential recursive calls of WarpX constructor. (#6223)
WarpX's constructor may build objects that call WarpX::getInstance,
which in turn build WarpX again if `m_instance` is nullptr. So we should
assign `this` to `m_instance` at the beginning of the constructor to
avoid the recursion.1 parent ab947bd commit ba5ade8
1 file changed
+3
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
320 | 320 | | |
321 | 321 | | |
322 | 322 | | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
323 | 326 | | |
324 | 327 | | |
325 | 328 | | |
| |||
0 commit comments