some fixes for compile errors