Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2002:
[Freeciv-Dev] Re: (PR#2650) Overflow in military_amortize
Home

[Freeciv-Dev] Re: (PR#2650) Overflow in military_amortize

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients:;
Subject: [Freeciv-Dev] Re: (PR#2650) Overflow in military_amortize
From: "Gregory Berkolaiko via RT" <rt@xxxxxxxxxxxxxx>
Date: Fri, 27 Dec 2002 11:18:22 -0800
Reply-to: rt@xxxxxxxxxxxxxx

Quoting "Per I. Mathisen via RT" <rt@xxxxxxxxxxxxxx>:

> 
> On Fri, 27 Dec 2002, Gregory Berkolaiko via RT wrote:
> > +int build_time = MAX((pcity ? pcity->shield_surplus : 1),
> > +                     ai->stats.average_production) / build_cost;
> >
> > Err...shall I send it to your maths tutor?   He might want to adjust your
> exam
> > marks ;)
> ...
> > P.S. find_city_by_id might return NULL, you know
> 
> I know that. Where is the error?

Oops, you do check for it.  Sorry.

But the maths mistake is there, unless I am completely mad.
 time = cost / production

G.



[Prev in Thread] Current Thread [Next in Thread]