mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 01:59:02 +00:00
Avoid a copy
Spotted by Coverity scan.
This commit is contained in:
parent
cc40330e00
commit
b1bbf64a28
@ -590,9 +590,8 @@ Buffer * Buffer::cloneWithChildren() const
|
||||
{
|
||||
BufferMap bufmap;
|
||||
cloned_buffers.emplace_back(new CloneList);
|
||||
CloneList_ptr clones = cloned_buffers.back();
|
||||
|
||||
cloneWithChildren(bufmap, clones);
|
||||
cloneWithChildren(bufmap, cloned_buffers.back());
|
||||
|
||||
// make sure we got cloned
|
||||
BufferMap::const_iterator bit = bufmap.find(this);
|
||||
|
Loading…
Reference in New Issue
Block a user