Fix issue found by Scrutinizer