Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
srbchannel: Defer reading when setting up read callback
Calling the callback while setting it up can make things complicated for clients, as the callback can do arbitrarily things. In this case, a protocol error caused the srbchannel to be owned by both the pstream and the native connection. Now the read callback is deferred, making sure the callback is called from a cleaner context where errors are handled appropriately. Reported-by: Tanu Kaskinen <tanu.kaskinen@linux.intel.com> Signed-off-by: David Henningsson <david.henningsson@canonical.com>
- Loading branch information
David Henningsson
committed
Sep 18, 2014
1 parent
f8aa823
commit e521d38
Showing
2 changed files
with
21 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters