(svn r12907) [0.6] -Backport from trunk r12906: 0.6 0.6.1-RC1
authorrubidium
Sat, 26 Apr 2008 20:54:56 +0000
branch0.6
changeset 10366 960aae8c20e2
parent 10364 40889da45fc9
child 10367 94c008da45c4
(svn r12907) [0.6] -Backport from trunk r12906:
- Fix: Vehicle groups, engine replacement rules and player/company names were not properly reset/freed after bankrupt (r12906)
[0.6] -Prepare: for 0.6.1-RC1.
changelog.txt
known-bugs.txt
os/debian/changelog
os/win32/installer/install.nsi
src/economy.cpp
src/players.cpp
--- a/changelog.txt	Fri Apr 25 19:27:27 2008 +0000
+++ b/changelog.txt	Sat Apr 26 20:54:56 2008 +0000
@@ -1,3 +1,40 @@
+0.6.1-RC1 (2008-04-26)
+------------------------------------------------------------------------
+- Fix: Vehicle groups, engine replacement rules and player/company names were not properly reset/freed after bankrupt (r12906)
+- Fix: Remove trams from savegames saved in OTTD without tram support, it is better than to simply crash [FS#1953] (r12904)
+- Fix: GCC on FreeBSD does not support -dumpmachine causing configure to fail. Use g++ instead [FS#1928] (r12876)
+- Fix: Make the town rating tests use less memory and much quicker (r12859)
+- Fix: Usage of AutoPtr made (trying to) build stuff very (time) expensive (r12857, r12855)
+- Fix: Ensure that prop 25 is set for all vehicles in the consist before other properties as it could cause desyncs (r12856)
+- Fix: Too much catenary was drawn about tunnel entrances, middle bridge pieces and non-rail station tiles (r12853, r12852)
+- Fix: Use YAPF for fairly old savegames from before YAPF was introduced (r12845)
+- Fix: The industry tick trigger should only be triggered once every 256 ticks, not every tick... Also bail out of the triggers a little earlier if you know they are not going to happen anyway (r12844)
+- Fix: Inconsistent use of 8/15-bitness of NewGRF callback results with respect to TTDP's implementation of the specification (r12819, r12818, r12759)
+- Fix: Possible out of bounds array access (r12809)
+- Fix: Enforce autorenew values range in command (r12808)
+- Fix: Vehicles could break down during loading and keep loading. The intention of the break down code is not to break down when having zero speed, therefor break downs now do not happen when loading [FS#1938] (r12795)
+- Fix: [OSX] In some rare cases when using an uncalibrated monitor the system colour space could not be retrieved. Show an error when this happens instead of just trying an assertion (r12776)
+- Fix: Slope checking for NewGRFs failed (r12759)
+- Fix: Check the TILE_NOT_SLOPED flag of the _north_ tile of multi-tile houses to decide if autoslope is allowed (r12717)
+- Fix: Do not move windows below the toolbar on resizes unless they would go behind the toolbar [FS#1904] (r12714)
+- Fix: Increase default sound buffer size only for Vista [FS#1914] (r12708)
+- Fix: Do not crash very hard on unrecognised savegames, just go back to the intro menu instead (r12707)
+- Fix: In some cases a news messages would not be shown [FS#1906] (r12683)
+- Fix: Removing road pieces from a town gave you twice the intended penalty [FS#1920] (r12682)
+- Fix: When a road vehicle has a tram only stop multiple times in a row in it's orders, only the first one would be skipped [FS#1918] (r12678)
+- Fix: Colour remaps on station sprites only worked for company colours [FS#1902] (r12674)
+- Fix: Remove buggy buoys at tile 0 from old TTDP savegames (r12642)
+- Fix: Possible NULL pointer dereference when reading some NewGRF data [FS#1913] (r12637)
+- Fix: Infinite loop in case your compiler decides that enums are unsigned by default (r12622)
+- Fix: The convert signal button disallowed signal dragging when the signal GUI was closed (r12577)
+- Fix: Binding to a specific IP could cause OpenTTD to not register properly with the masterserver if one has multiple external interfaces (r12574)
+- Fix: min() has 32bit arguments, clamping of 64bit values did not work (r12572)
+- Fix: Towns could not terraform when inflation rised terraform prices enough (r12564)
+- Fix: Do not affect town rating change by the order in which we examine stations (r12561)
+- Fix: Redraw the signal GUI when the signal drag density changes in the patch settings and vice versa (r12553)
+- Fix: Do not install scenarios into the current user's homedir when running 'make install', that is silly. Simply always install scenarios system wide instead (r12542)
+
+
 0.6.0 (2008-04-01)
 ------------------------------------------------------------------------
 - Fix: Final formatting of some string codes from NewGRFs was not done correctly [FS#1889] (r12488)
--- a/known-bugs.txt	Fri Apr 25 19:27:27 2008 +0000
+++ b/known-bugs.txt	Sat Apr 26 20:54:56 2008 +0000
@@ -11,10 +11,12 @@
 If the bug report is closed, it has been fixed, which then can be verified
 in the latest SVN version of /trunk.
 
-Bugs for 0.6.0
+Bugs for 0.6.1
 ------------------------------------------------------------------------
 URL: http://bugs.openttd.org
 
+- 1944	Road vehicles not picking empty drivethrough platform
+- 1923	Unique names not always enforced
 - 1891	Go to depot for servicing is forgotten
 - 1890	Airplanes copy helipcopters goto heliport order
 - 1885	Almost all unserved industries die in big maps
--- a/os/debian/changelog	Fri Apr 25 19:27:27 2008 +0000
+++ b/os/debian/changelog	Sat Apr 26 20:54:56 2008 +0000
@@ -1,3 +1,9 @@
+openttd (0.6.1~RC1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Matthijs Kooijman <m.kooijman@student.utwente.nl>  Sat, 26 Apr 2008 22:55:00 +0200
+
 openttd (0.6.0) unstable; urgency=low
 
   * New upstream release.
--- a/os/win32/installer/install.nsi	Fri Apr 25 19:27:27 2008 +0000
+++ b/os/win32/installer/install.nsi	Sat Apr 26 20:54:56 2008 +0000
@@ -1,6 +1,6 @@
 !define APPNAME "OpenTTD"   ; Define application name
-!define APPVERSION "0.6.0"  ; Define application version
-!define INSTALLERVERSION 45 ; NEED TO UPDATE THIS FOR EVERY RELEASE!!!
+!define APPVERSION "0.6.1"  ; Define application version
+!define INSTALLERVERSION 46 ; NEED TO UPDATE THIS FOR EVERY RELEASE!!!
 
 !define APPURLLINK "http://www.openttd.org"
 !define APPNAMEANDVERSION "${APPNAME} ${APPVERSION}"
--- a/src/economy.cpp	Fri Apr 25 19:27:27 2008 +0000
+++ b/src/economy.cpp	Sat Apr 26 20:54:56 2008 +0000
@@ -45,6 +45,7 @@
 #include "rail_map.h"
 #include "signal_func.h"
 #include "gfx_func.h"
+#include "autoreplace_func.h"
 
 #include "table/strings.h"
 #include "table/sprites.h"
@@ -455,6 +456,19 @@
 		UpdateSignalsInBuffer();
 	}
 
+	/* In all cases clear replace engine rules.
+	 * Even if it was copied, it could interfere with new owner's rules */
+	RemoveAllEngineReplacementForPlayer(GetPlayer(old_player));
+
+	if (new_player == PLAYER_SPECTATOR) {
+		RemoveAllGroupsForPlayer(old_player);
+	} else {
+		Group *g;
+		FOR_ALL_GROUPS(g) {
+			if (g->owner == old_player) g->owner = new_player;
+		}
+	}
+
 	/* Change color of existing windows */
 	if (new_player != PLAYER_SPECTATOR) ChangeWindowOwner(old_player, new_player);
 
--- a/src/players.cpp	Fri Apr 25 19:27:27 2008 +0000
+++ b/src/players.cpp	Sat Apr 26 20:54:56 2008 +0000
@@ -453,6 +453,8 @@
 	/* Find a free slot */
 	FOR_ALL_PLAYERS(p) {
 		if (!p->is_active) {
+			free(p->name);
+			free(p->president_name);
 			PlayerID i = p->index;
 			memset(p, 0, sizeof(Player));
 			memset(&_players_ai[i], 0, sizeof(PlayerAI));
@@ -912,9 +914,6 @@
 			ChangeOwnershipOfPlayerItems(p->index, PLAYER_SPECTATOR);
 			p->is_active = false;
 		}
-		RemoveAllEngineReplacementForPlayer(p);
-		RemoveAllGroupsForPlayer(p->index);
-
 	} break;
 
 	case 3: { /* Merge a company (#1) into another company (#2), elimination company #1 */