mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-07 12:32:26 +00:00
Avoid null pointer dereference
Spotted by coverity. In the real world, getInset should never return nullptr when isInset is true.
This commit is contained in:
parent
a900667ea1
commit
b365a47112
@ -2367,8 +2367,8 @@ int Paragraph::Private::startTeXParParams(BufferParams const & bparams,
|
||||
&& !layout_->pass_thru
|
||||
&& curAlign != LYX_ALIGN_CENTER) {
|
||||
if (!owner_->empty()
|
||||
&& (owner_->isInset(0)
|
||||
&& owner_->getInset(0)->lyxCode() == VSPACE_CODE))
|
||||
&& owner_->getInset(0)
|
||||
&& owner_->getInset(0)->lyxCode() == VSPACE_CODE)
|
||||
// If the paragraph starts with a vspace, the \\noindent
|
||||
// needs to come after that (as it leaves vmode).
|
||||
// If the paragraph consists only of the vspace,
|
||||
|
Loading…
Reference in New Issue
Block a user