[KDevPlatform/1.2] 5774a52: Check that git is installed when loading Git Suppo
Aleix Pol
aleixpol at kde.org
Mon Dec 20 12:46:04 UTC 2010
On Mon, Dec 20, 2010 at 12:51 PM, Dmitry Risenberg <
dmitry.risenberg at gmail.com> wrote:
> 2010/12/20 Aleix Pol <aleixpol at kde.org>:
> > Maybe you could try to explore why is this crashing? I don't like to
> change
> > the plugin interface to provide errors, we could end up with code
> checking
> > if plugins are wrong all over the place.
> > Aleix
>
> The reason is that the plugin object returned from
> KServiceTypeTrader::createInstanceFromQuery (plugincontroller.cpp:435)
> is used by some later initialization code, particularly in
> ProjectPrivate::loadVersionControlPlugin, and this code does not know
> that the plugin has in fact been unloaded. Unloading via
> PluginController::unloadPlugin deletes the plugin object, so accessing
> it later is accessing freed memory.
> To sum up, the plugin itself cannot know whether it is safe to unload
> at a given moment, so it is up to PluginController to decide, which,
> in turn, has to check for errors. In fact it seems strange that there
> is no error reporting mechanism, and it is just assumed that the
> plugin always loads correctly.
>
> --
> Dmitry Risenberg
>
> --
> KDevelop-devel mailing list
> KDevelop-devel at kdevelop.org
> https://barney.cs.uni-potsdam.de/mailman/listinfo/kdevelop-devel
>
On the other hand, plugins can be unloaded by the user and we have to be
prepared for that.
Aleix
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20101220/a086fa40/attachment.html>
More information about the KDevelop-devel
mailing list