-
Notifications
You must be signed in to change notification settings - Fork 104
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
Fixed video/audio end services sometimes not being sent when secondary transport shuts down #1566
Fixed video/audio end services sometimes not being sent when secondary transport shuts down #1566
Conversation
Co-Authored-By: Joel Fischer <[email protected]>
…transport' of https://github.com/smartdevicelink/sdl_ios into bugfix/issue_1551_video_end_service_not_sent_secondary_transport # Conflicts: # SmartDeviceLink/SDLSecondaryTransportManager.m
…ent_secondary_transport # Conflicts: # SmartDeviceLink/SDLLifecycleManager.m # SmartDeviceLink/SDLStreamingAudioLifecycleManager.m # SmartDeviceLink/SDLStreamingMediaManager.h # SmartDeviceLink/SDLStreamingMediaManager.m # SmartDeviceLinkTests/DevAPISpecs/SDLStreamingAudioLifecycleManagerSpec.m # SmartDeviceLinkTests/DevAPISpecs/SDLStreamingVideoLifecycleManagerSpec.m
SmartDeviceLink/SDLTCPTransport.m
Outdated
[self sdl_cancelIOThread]; | ||
|
||
if (self.ioThread == nil) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it ever be nil
here? I don't think that it can be since the only place it's set to nil
is below in the performSelector
for sdl_disconnect
, and we already checked for nil above.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed this code after testing. It does not appear to be necessary anymore.
SmartDeviceLink/SDLTCPTransport.m
Outdated
// The `ioThread` could not be woken up to be cancelled. Switch to the `ioThread` and perform the cleanup of the input/output streams | ||
[self performSelector:@selector(sdl_disconnect) onThread:self.ioThread withObject:nil waitUntilDone:NO]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't seem correct. If the ioThread
is cancelled, it's not automatically nil
right? So this will always run?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed this code after testing. It does not appear to be necessary anymore.
SmartDeviceLinkTests/DevAPISpecs/SDLStreamingAudioLifecycleManagerSpec.m
Outdated
Show resolved
Hide resolved
I did as much other testing as was possible. I had some issues with a Sync 3.4 Bluetooth setup where I was getting SetAppIcon rejected and ListFiles disallowed, so I was unable to do extensive testing of this particular case. All other cases seem to be working very well. |
Fixes #1551, #1561, #1471, #1479
This PR is ready for review.
Risk
This PR makes minor API changes.
Testing Plan
Unit Tests
Unit tests added/fixed for the streaming media manager classes.
Core Tests
Primary Transport Only Tests (Tested on SYNC 4.0 and SYNC 3.0)
hmiLevel
goes toBACKGROUND
and back toFULL
).hmiLevel
goes toLIMITED
and back toFULL
).Secondary Transport Tests (Tested on SYNC 4.0)
hmiLevel
goes toBACKGROUND
and back toFULL
).hmiLevel
goes toLIMITED
and back toFULL
).Smoke tests performed with:
Core version / branch / commit hash / module tested against: SYNC 4 (20016_DEVTEST) and SYNC 3.0
HMI name / version / branch / commit hash / module tested against: SYNC 4 (20016_DEVTEST) and SYNC 3.0
Summary
hmiLevel
being reset when the secondary transport closed. This is not necessary as the primary transport is still open.Changelog
Bug Fixes
SDLH264VideoEncoder
class sometimes randomly invalidates itself when the device app is backgrounded. Handling was added to reset the pixel buffer pool when it becomesnil
.CLA