Andre Poenitz wrote:
Looks like the problem is here:
case LFUN_GRAPHICS_EDIT: {
FuncRequest fr(action, argument);
InsetGraphics().dispatch(view()->cursor(), fr);
break;
}
This creates a null InsetGraphics on which to call dispatch(), and the
buffer isn't set. This is likely also to be a problem a couple lines
earlier:
case LFUN_EXTERNAL_EDIT: {
BOOST_ASSERT(lyx_view_);
FuncRequest fr(action, argument);
InsetExternal().dispatch(view()->cursor(), fr);
break;
}
Looks like we'll get the same crash, I'd think.
I don't know this code well enough to know how to fix it.
InsetExternal inset;
inset.setBuffer(...);
inset.dispatch();
for ... use some Buffer refrence. Usually there's some nearby,
view()->buffer() or such.
OK. I can certainly do this.
Should we permit inset creation without a buffer, anyway?
rh