On Tue Jul 30 13:12:14 2024 +0000, Nikolay Sivov wrote:
It's not clear what it should do if MFVP_MESSAGE_PROCESSINPUTNOTIFY keeps failing, of if MFVP_MESSAGE_INVALIDATEMEDIATYPE fails. Regarding the tests, the main problem is that such tests quickly become unmanageable, once you add some other paths to test different situation. Also it's covered with broken() checks all over. It might be better to figure out first if we need to retry more than once, and then strip the tests and attach them as a plain diff for this MR.
Thanks for taking a look @nsivov.
I've done as you suggested. I added some tests to see what happens when an error occurs with either `MFVP_MESSAGE_PROCESSINPUTNOTIFY` or `MFVP_MESSAGE_INVALIDATEMEDIATYPE` and found Windows will in fact loop indefinitely if `MFVP_MESSAGE_PROCESSINPUTNOTIFY` keeps returning `MF_E_TRANSFORM_TYPE_NOT_SET`. So I have modified the MR so we do the same.
I also found that on another error (such as `E_FAIL`), it will not retry but will raise an `MEError`. I've added a second commit to reflect this.
I've also removed the tests from the MR, and instead I have attached them here.[cw_23939_tests.patch](/uploads/5ec73aaba969babf7d8c6b16a4c8d5a0/cw_23939_tests.patch)