Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP


[fix] make sure we actually stop the service addon before upgrading it #2069

merged 1 commit into from

4 participants


this is a fix to make sure we actually stop service addons before we update them.

currently we attempt to stop the addon that is in a zip and fail miserably as we cannot find that addon path in database, after install we start the new one and endup with 2 versions of the same addon running.

what happens now is that addon id from zip is used to find the actual installed addon and stop it, install the newer version and start it again.

@ronie if you could test please, I think its a FIX for Frodo


tested and works as expected.


push and add to frodo backports list

@amet amet merged commit 58eb6a9 into xbmc:master

Would it also fix service script failed on uninstall?



19:56:44 T:140662014445312   DEBUG: FileManager: delete folder /home/ronie/.xbmc/addons/script.xbmc.boblight/
19:56:44 T:140662072739584   DEBUG: Process - The source file to load is /home/ronie/.xbmc/addons/script.xbmc.boblight/
19:56:44 T:140662014445312    INFO: ADDON: cpluff: 'Could not read plug-in directory /opt/xbmc-20120113/lib/xbmc/addons: No such file or directory'
19:56:44 T:140662072739584   ERROR: /home/ronie/.xbmc/addons/script.xbmc.boblight/ not found!
19:56:44 T:140662072739584   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.IOError'>
                                            Error Contents: (2, 'No such file or directory', '/home/ronie/.xbmc/addons/script.xbmc.boblight/')
                                            IOError: (2, 'No such file or directory', '/home/ronie/.xbmc/addons/script.xbmc.boblight/')
                                            -->End of Python script error report<--

looks like xbmc is trying to start the addon after it has been uninstalled

@amet amet deleted the amet:service_addon_stop branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 3 additions and 1 deletion.
  1. +3 −1 xbmc/addons/AddonInstaller.cpp
4 xbmc/addons/AddonInstaller.cpp
@@ -556,7 +556,9 @@ bool CAddonInstallJob::OnPreInstall()
if (m_addon->Type() == ADDON_SERVICE)
- boost::shared_ptr<CService> service = boost::dynamic_pointer_cast<CService>(m_addon);
+ AddonPtr addon;
+ ADDON::CAddonMgr::Get().GetAddon(m_addon->ID(), addon);
+ boost::shared_ptr<CService> service = boost::dynamic_pointer_cast<CService>(addon);
if (service)
return true;
Something went wrong with that request. Please try again.