Minor fixes that resulted in compile errors on some platforms