[Freeciv-Dev] Re: Remove map_adjust_[xy] invocations from server (PR#10
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Tue, 23 Oct 2001, hawk@xxxxxxxxxxxxxxxxxxxxxxx wrote:
>
> We have to go through the code and remove is_real_tile,
> normalize_map_pos and is_normal_map_pos. Everything is fine if the
> positions these methods work on are used in the function as an
> arguement to some access method. What happens if this isn't the
> case?
I don't see what you're getting at. We will have to go through and
replace these things anyway. Also, failure to run a given coordinate
pair through CHECK_POS() or whatever is not a bug in itself, it is
just a missed opportunity to find down a bug. It's not worthwhile
being paranoid about this; in practise a bug will manifest itself soon
enough.
>> It would be a good idea to add those checks in places where it is
>> obvious that a check in map_inx() is not enough, such as
>> same_pos().
>
> This is my first suggestion.
Then we are in violent agreement...
>> The idea is to disable it by default, and let people turn it back
>> on when they make changes to iteration macros etc. that need
>> testing of this sort. Since that is a distinct minority of the
>> time, we do not need to care that much about how much time it
>> takes. I don't think it is going to take that much more time than
>> the current approach (always check, always fix).
>
> I would vote for the ignore the case.
Sorry, what do you mean?
> - used for an outgoing packet.
>
> For the last case (and also on general) I would wish a more strict
> testing of map positions which came from packets (server rejects,
> client aborts).
I'll leave that to someone who knows the packet protocol better.
A priori the most sensible thing to do is to always emit normalised
coordinates, and reject coordinates which are not. But there is also
backwards compatibility to consider.
--
Big Gaute http://www.srcf.ucam.org/~gs234/
By MEER biz doo SCHOIN..
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocationsfromserver (PR#1003), (continued)
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocationsfromserver (PR#1003), Jason Dorje Short, 2001/10/15
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations fromserver (PR#1003), Raimar Falke, 2001/10/15
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations fromserver (PR#1003), Ross W. Wetmore, 2001/10/15
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations fromserver (PR#1003), Raimar Falke, 2001/10/16
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations fromserver (PR#1003), Ross W. Wetmore, 2001/10/17
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations from server (PR#1003), Raimar Falke, 2001/10/13
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations from server (PR#1003), Gaute B Strokkenes, 2001/10/21
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations from server (PR#1003), Raimar Falke, 2001/10/22
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations from server (PR#1003), Gaute B Strokkenes, 2001/10/22
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations from server (PR#1003), Raimar Falke, 2001/10/23
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations from server (PR#1003),
Gaute B Strokkenes <=
- [Freeciv-Dev] Re: Remove map_adjust_[xy] invocations from server (PR#1003), Raimar Falke, 2001/10/24
|
|