Skip to content

Commit

Permalink
Merge pull request #777 from johzzy/master
Browse files Browse the repository at this point in the history
fix crash in BGMPlayThrough::IsRunningSomewhereOtherThanBGMApp
  • Loading branch information
kyleneideck authored Dec 6, 2024
2 parents 0aea54f + 7e592eb commit 4b7caee
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions BGMApp/BGMApp/BGMPlayThrough.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -933,9 +933,8 @@ void BGMPlayThrough::HandleBGMDeviceIsRunningSomewhereOtherThanBGMApp(BGMPlay
// static
bool BGMPlayThrough::IsRunningSomewhereOtherThanBGMApp(const BGMAudioDevice& inBGMDevice)
{
return CFBooleanGetValue(
static_cast<CFBooleanRef>(
inBGMDevice.GetPropertyData_CFType(kBGMRunningSomewhereOtherThanBGMAppAddress)));
auto type = inBGMDevice.GetPropertyData_CFType(kBGMRunningSomewhereOtherThanBGMAppAddress);
return type && CFBooleanGetValue(static_cast<CFBooleanRef>(type));
}

#pragma mark IOProcs
Expand Down

0 comments on commit 4b7caee

Please sign in to comment.