some fixes in beginning of program