Index: common/aicore/cm.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/common/aicore/cm.c,v retrieving revision 1.16 diff -u -u -r1.16 cm.c --- common/aicore/cm.c 2003/11/13 20:11:31 1.16 +++ common/aicore/cm.c 2003/11/17 19:55:42 @@ -325,7 +325,8 @@ int i; if (!parameter->allow_specialists - && (result->entertainers + result->scientists + result->taxmen) > 0) { + && (result->entertainers + result->scientists + result->taxmen) > + MAX(0,cache3.pcity->size - cache3.fields_available_total)) { return FALSE; } @@ -1390,14 +1391,12 @@ continue; } - if (parameter->allow_specialists) { - find_best_specialist_arrangement(pcity, parameter, current, &result, - &major_fitness, &minor_fitness); - if (!result.found_a_valid) { - freelog(OPTIMIZE_FINAL_LOG_LEVEL2, " not enough secondary"); - not_enough_secondary++; - continue; - } + find_best_specialist_arrangement(pcity, parameter, current, &result, + &major_fitness, &minor_fitness); + if (!result.found_a_valid) { + freelog(OPTIMIZE_FINAL_LOG_LEVEL2, " not enough secondary"); + not_enough_secondary++; + continue; } freelog(OPTIMIZE_FINAL_LOG_LEVEL2, " is ok");