threading: Get rid of warnings with old compilers