mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-06 05:35:47 +01:00
fix assert for non-existing MIDI patch-names
typename boost::detail::sp_member_access<T>::type boost::shared_ptr<T>::operator->() const [with T = MIDI::Name::ChannelNameSet; typename boost::detail::sp_member_access<T>::type = MIDI::Name::ChannelNameSet*]: Assertion `px != 0' failed.
This commit is contained in:
parent
7e857b2264
commit
e281f5653c
1 changed files with 3 additions and 1 deletions
|
|
@ -542,7 +542,9 @@ MasterDeviceNames::channel_name_set_by_device_mode_and_channel(const std::string
|
|||
boost::shared_ptr<Patch>
|
||||
MasterDeviceNames::find_patch(const std::string& mode, uint8_t channel, const PatchPrimaryKey& key)
|
||||
{
|
||||
return channel_name_set_by_device_mode_and_channel(mode, channel)->find_patch(key);
|
||||
boost::shared_ptr<ChannelNameSet> cns = channel_name_set_by_device_mode_and_channel(mode, channel);
|
||||
if (!cns) return boost::shared_ptr<Patch>();
|
||||
return cns->find_patch(key);
|
||||
}
|
||||
|
||||
boost::shared_ptr<ChannelNameSet>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue