зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1630223: Replace remaining occurrences of Unsound_IsClosed with !CanSend in CanvasTranslator. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D71039 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
8b3995f814
Коммит
6254206e21
|
@ -151,7 +151,7 @@ ipc::IPCResult CanvasTranslator::RecvResumeTranslation() {
|
|||
}
|
||||
|
||||
void CanvasTranslator::StartTranslation() {
|
||||
if (!TranslateRecording() && !GetIPCChannel()->Unsound_IsClosed()) {
|
||||
if (!TranslateRecording() && GetIPCChannel()->CanSend()) {
|
||||
MOZ_ALWAYS_SUCCEEDS(mTranslationTaskQueue->Dispatch(
|
||||
NewRunnableMethod("CanvasTranslator::StartTranslation", this,
|
||||
&CanvasTranslator::StartTranslation)));
|
||||
|
@ -194,7 +194,7 @@ bool CanvasTranslator::TranslateRecording() {
|
|||
[&](RecordedEvent* recordedEvent) -> bool {
|
||||
// Make sure that the whole event was read from the stream.
|
||||
if (!mStream->good()) {
|
||||
if (GetIPCChannel()->Unsound_IsClosed()) {
|
||||
if (!GetIPCChannel()->CanSend()) {
|
||||
// The other side has closed only warn about read failure.
|
||||
gfxWarning() << "Failed to read event type: "
|
||||
<< recordedEvent->GetType();
|
||||
|
@ -245,7 +245,7 @@ bool CanvasTranslator::TranslateRecording() {
|
|||
case _typeenum: { \
|
||||
auto e = _class(*mStream); \
|
||||
if (!mStream->good()) { \
|
||||
if (GetIPCChannel()->Unsound_IsClosed()) { \
|
||||
if (!GetIPCChannel()->CanSend()) { \
|
||||
/* The other side has closed only warn about read failure. */ \
|
||||
gfxWarning() << "Failed to read event type: " << _typeenum; \
|
||||
} else { \
|
||||
|
|
Загрузка…
Ссылка в новой задаче