fixed compile error with main