[Freeciv-Dev] [patch #3876] Remove redundant tile_remove_base() call

2013-04-28 Thread Marko Lindqvist
Update of patch #3876 (project freeciv):

  Status:  Ready For Test => Done   
 Open/Closed:Open => Closed 


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #3876] Remove redundant tile_remove_base() call

2013-04-22 Thread Marko Lindqvist
Update of patch #3876 (project freeciv):

  Status:None => Ready For Test 
 Assigned to:None => cazfi  
 Planned Release: => 2.5.0  


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #3876] Remove redundant tile_remove_base() call

2013-04-22 Thread Emmet Hikory
URL:
  

 Summary: Remove redundant tile_remove_base() call
 Project: Freeciv
Submitted by: persia
Submitted on: Tue 23 Apr 2013 06:54:53 AM JST
Category: general
Priority: 5 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any
 Planned Release: 

___

Details:

Extracted from discussion in patch #3826

tile.c:tile_change_terrain() checks if fc_funcs->destroy_base is set, and
either calls the callback or calls tile_remove_base() if the callback is
unset.  Then, just to make sure, tile_remove_base() is called again. 
fc_funcs->destroy_base is set to NULL for the client and
maphand.c:destroy_base() for the server, which function also calls
tile_remove_base().

In practice, this means that for calls from the client, tile_remove_base() is
called twice in immediate succession within tile_change_terrain(), and for
calls from the server, tile_remove_base() is called from destroy_base() and
then immediately thereafter from tile_change_terrain().

This patch removes the redundant call and adds a comment indicating that the
code assumes that tile_remove_base() will be called by any function assigned
to fc_funcs->destroy_base().




___

File Attachments:


---
Date: Tue 23 Apr 2013 06:54:53 AM JST  Name:
remove-redundant-tile_remove_base-call.patch  Size: 880B   By: persia



___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev