RESOLVED FIXED 232508
Improve error handling in sendWithAsyncReply()
https://bugs.webkit.org/show_bug.cgi?id=232508
Summary Improve error handling in sendWithAsyncReply()
Chris Dumez
Reported 2021-10-29 14:52:19 PDT
Improve error handling in sendWithAsyncReply().
Attachments
Patch (2.97 KB, patch)
2021-10-29 14:58 PDT, Chris Dumez
no flags
Patch (7.16 KB, patch)
2021-10-29 16:27 PDT, Chris Dumez
no flags
Chris Dumez
Comment 1 2021-10-29 14:58:14 PDT
Darin Adler
Comment 2 2021-10-29 15:05:15 PDT
Comment on attachment 442866 [details] Patch Should we test this?
Chris Dumez
Comment 3 2021-10-29 15:09:26 PDT
(In reply to Darin Adler from comment #2) > Comment on attachment 442866 [details] > Patch > > Should we test this? We'd need a way to keep the IPC::Connection object alive after we've invalidated it. If the IPC::Connection object gets destroyed promptly, then there is no issue since its destructor will call the async reply handlers. I noticed this when working on another patch where I mistakenly leaked a Connection object and one test was timing out because the sendWithAsyncReply() completion handler was never getting called. I will see if there is an easy way to write a test for this but it is not super trivial.
Chris Dumez
Comment 4 2021-10-29 16:27:55 PDT
Chris Dumez
Comment 5 2021-10-29 16:28:37 PDT
(In reply to Chris Dumez from comment #4) > Created attachment 442879 [details] > Patch I added an API test.
EWS
Comment 6 2021-10-30 18:24:45 PDT
Committed r285086 (243728@main): <https://commits.webkit.org/243728@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 442879 [details].
Radar WebKit Bug Importer
Comment 7 2021-10-30 18:25:17 PDT
Note You need to log in before you can comment on or make changes to this bug.