To fix this issue at the root would be to have your mail server configured in such a way that emails which contain key words, such as 'Out of office', are ignored. Although that would typically be an IT Helpdesk remit and not for a Salesforce Admin / Developer.
From a Salesforce Developer perspective, you can write a trigger which auto-deletes or prevents a new email thread hitting the case. This link gives some helpful information.
From a Salesforce Admin perspective, it may be worth researching an App on the AppExchange. Email to Case premium is very helpful for preventing email2case loops, but I am unsure if it prevents email threading of emails which contain key words. Also from a Salesforce Admin perspective, although this isn't ideal, you can create new custom fields and have workflows / process builders created which would ignore calculating case open times etc from threads which contain key words.