fixes gcc warnings/errors