Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Music]Fix when song info dialog called by Python with non-array artistid property #13649

Merged
merged 1 commit into from Mar 17, 2018

Conversation

@DaveTBlake
Copy link
Member

commented Mar 14, 2018

Fix issue when song info dialog is opened by an addon.

CMusicInfoLoader::LoadAdditionalTagInfo() is expecting the item artistid property (if present) to be an array, as this is what is set by loading the data from the db. However this property is vulnerable to being set incorrectly by an addon which can only set string values.

For example:

import xbmcgui

listitem = xbmcgui.ListItem('Foo')
listitem.setInfo('music', {'dbid': 1, 'mediatype': 'song'})
listitem.setProperty('artistid', '[1]')
xbmcgui.Dialog().info(listitem)

Thanks for spotting this @ronie

…n has set it incorrectly
@ronie

This comment has been minimized.

Copy link
Member

commented Mar 14, 2018

thx!
tested and it solves my issue.

@DaveTBlake DaveTBlake merged commit 417cd69 into xbmc:master Mar 17, 2018
1 check passed
1 check passed
default You're awesome. Have a cookie
Details
@DaveTBlake DaveTBlake deleted the DaveTBlake:SongLoadOnlyDB branch Mar 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.