fixed warnings on Linux/Mac