Modifications to remove compilation errors and warnings