Fixes for compilation errors