Fix compiler warnings by switching enum type back to int.