fix compiler warning and indentation