Closed Bug 1424981 Opened 2 years ago Closed 2 years ago
Blob Storage must keep the file locked during the IPC communication
bkelly showed me this crash: https://treeherder.mozilla.org/logviewer.html#?job_id=151371386&repo=try&lineNumber=10724 Here we have I/O errors during the creation of a TemporaryIPCBlobInputStream object by the parent actor. This can happen only if the temporary file has been deleted during the operation and this could happen because the File Handle is closed by the child actor, before asking for the IPCBlob. Between that time, and when the parent actor does the operation, nsAnonTempFileRemover is able to delete the temporary file.
Comment on attachment 8936563 [details] [diff] [review] patch I tried and failed to understand this. We may call CloseFD() also elsewhere in failure cases. Why we don't need to change those? Please fix or explain.
> We may call CloseFD() also elsewhere in failure cases. Why we don't need to > change those? If we fail, we want to release the temporary file. We don't create the blob if we fail. In general, we call SendOperationFailed() in these scenarios: 1. MutableBlobStorage::TemporaryFileCreated but the storage has been already closed. In this case we dispatch a CloseFileRunnable. 2. ErrorPropagated(). In this case, before dispatching ErrorPropagationRunnable() we call CloseFD().
Comment on attachment 8936563 [details] [diff] [review] patch I think I may understand this.
Attachment #8936563 - Flags: review+
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/mozilla-inbound/rev/9ffdabd433a0 MutableBlobStorage must keep the file locked during the IPC communication, r=smaug
You need to log in before you can comment on or make changes to this bug.