I can’t find the link now, but apparently there is a rule that the Speaker has to submit a ranked list of people to fill the role in case he is incapacitated, out of town, whatever and something Speakerish needs doing. Whoever maintains that list has verified that Boehner did that, but did not release the names.
My guess would be that McCarthy is #1 on it.