Commit Graph

47998 Commits (951a50ddd9fa60784fc9b9f03cf357e6c1e70cbc)
 

Author SHA1 Message Date
Michael Lutz c7b9987d08 Codechange: Switch DropDownList to directly use std::vector, thus making AutoDeleteSmallVector obsolete.
DropDownListItem are strongly managed using std::unique_ptr to ensure leak-free handling. Appropriate use
of move-semantics make intent a lot clearer than parameter comments and allows the compiler to generate
copy-free code for most situations.
6 years ago
Michael Lutz d3e113eb5f Codechange: Use std::vector instead of AutoDeleteSmallVector in GS text handling. 6 years ago
Michael Lutz baf9229931 Codechange: Replace AutoDeleteSmallVector with direct std::vector use in text layout code. 6 years ago
Michael Lutz 329bb52613 Codechange: Store text layout runs directly as values in a std::vector instead of heap allocated.
This reduces memory allocations and heap fragmentation.
6 years ago
Michael Lutz 9325d63d8e Fix: Forgotten override keywords for DropDownListIconItem. 6 years ago
Michael Lutz fbc4cef180 Codechange: Use override specifier for text layout classes. 6 years ago
Michael Lutz d95c7083ea Fix: Don't crash if reading a GS string file from disk produces an error.
The raw_strings vector may not include NULLs as no consumer can deal with it.
6 years ago
Jonathan G Rennison 58c27ab59e Merge branch 'crashlog_improvements' into jgrpp 6 years ago
Jonathan G Rennison 69d2d3e278 Crashlog: Limit total number of news items 6 years ago
Jonathan G Rennison d5ee9d34da Merge branch 'cpp-11' into crashlog_improvements
# Conflicts:
#	Makefile.src.in
#	projects/determineversion.vbs
#	source.list
#	src/crashlog.cpp
#	src/misc.cpp
#	src/os/unix/crashlog_unix.cpp
#	src/os/windows/crashlog_win.cpp
#	src/rev.h
#	src/thread/thread.h
#	src/thread/thread_morphos.cpp
#	src/thread/thread_none.cpp
#	src/thread/thread_os2.cpp
#	src/thread/thread_pthread.cpp
#	src/thread/thread_win32.cpp
6 years ago
Jonathan G Rennison 361758b516 Merge branches 'crashlog_improvements', 'save_ext' into jgrpp
# Conflicts:
#	Makefile.src.in
#	projects/openttd_vs140.vcxproj
#	projects/openttd_vs140.vcxproj.filters
#	projects/openttd_vs141.vcxproj
#	projects/openttd_vs141.vcxproj.filters
#	projects/openttd_vs142.vcxproj
#	projects/openttd_vs142.vcxproj.filters
#	src/core/smallstack_type.hpp
#	src/linkgraph/linkgraphjob.cpp
#	src/linkgraph/linkgraphjob.h
#	src/misc.cpp
#	src/network/network_udp.cpp
#	src/openttd.cpp
#	src/saveload/saveload.cpp
6 years ago
Jonathan G Rennison 7f80884047 Merge branch 'cpp-11' into save_ext
# Conflicts:
#	src/saveload/saveload.cpp
#	src/settings.cpp
#	src/settings_gui.cpp
6 years ago
Jonathan G Rennison 01261daec0 Merge branch 'master' into cpp-11
# Conflicts:
#	config.lib
6 years ago
translators 0a883afe19 Update: Translations from eints
luxembourgish: 20 changes by Phreeze
6 years ago
Jonathan G Rennison 070160af40 Save point used when adding station to viewport kd tree, use for removal 6 years ago
Jonathan G Rennison 3807f0551d Limit maximum recursion depth in StationViewWindow::EstimateDestinations 6 years ago
peter1138 72b72dbec3 Add: Press ctrl to build diagonal rivers in scenario editor. 6 years ago
PeterN 812886ca61
Fix #7478: Don't remove NewGRF objects on company take-over. (#7483) 6 years ago
kiwitreekor bc9b47d2e5 Fix #6222: Advanced sprite layout sometimes showed incorrect railtype ground tile 6 years ago
Jonathan G Rennison 99055c22cb Fix string format issue in Japanese translation 6 years ago
Jonathan G Rennison c0b402a74c Merge branch 'pr-82' into jgrpp 6 years ago
Jonathan G Rennison 99f3ebe1fd Merge branch 'pr-78' into jgrpp 6 years ago
Jonathan G Rennison 74e5e04724 Fix: Crash due to use of invalid iterator in ClientNetworkContentSocketHandler
In particular this crash can be observed when using the
bootstrap GUI to download the base graphics.

In ClientNetworkContentSocketHandler::OnReceiveContentInfo
ClientNetworkContentSocketHandler::callbacks is iterated, using an iterator
cb->OnReceiveContentInfo() is called (cb is of type BootstrapAskForDownloadWindow)
This calls new BootstrapContentDownloadStatusWindow()
This inherits from BaseNetworkContentDownloadStatusWindow
The constructor of which calls _network_content_client.AddCallback(this)
This reallocates the std::vector which is being iterated in ClientNetworkContentSocketHandler::OnReceiveContentInfo
This results in iter being invalid, and an assertion failure occurs shortly
afterwards due to its use in the next iteration of cb->OnReceiveContentInfo()

Adjust all locations where ClientNetworkContentSocketHandler::callbacks
is iterated to avoid problematic behaviour
6 years ago
nikolas eab8ab40d9
Fix typo in readme: sufficienty -> sufficiently 6 years ago
glx22 3e608afa6c
Fix: [Windows] OpenTTD window may be inactive when an error happens (#7482) 6 years ago
Michael Lutz 967b27a2c1 Codechange: C++11 STL has a function for getting the number of CPU cores. 6 years ago
Michael Lutz ae748166d0 Codechange: Use platform independent C++11 function for sleeping on a thread. 6 years ago
Michael Lutz 94c5269fa7 Codechange: Use atomic variables for thread synchronization where useful. 6 years ago
Michael Lutz 05bc2ed7cb Codechange: Replace custom thread code with C++11 thread objects.
We assume a conforming C++11 compiler environment that has a valid <thread>-header.
Failure to run a real thread is handled gracefully.
6 years ago
Michael Lutz 05f4e73608 Codechange: Replace custom mutex code with C++11 mutex'es.
A conforming compiler with a valid <mutex>-header is expected.
Most parts of the code assume that locking a mutex will never fail unexpectedly,
which is generally true on all common platforms that don't just pretend to
be C++11. The use of condition variables in driver code is checked.
6 years ago
Michael Lutz 3b86f54fc7 Fix: [OSX] .mm files are C++ files, not C files. 6 years ago
glx22 90a91f1d0d
Fix: [MSVC] don't force SDK version (#7474) 6 years ago
glx22 a1e492d0d8
Fix #7439: don't overwrite CompanyRemoveReason with ClientID (#7465) 6 years ago
Samu fb6e31ca43 Cleanup 3f32711: Don't apply forbid 90 deg turn settings for ships. 6 years ago
Jonathan G Rennison a6887d7010 Version: Committing version data for tag: jgrpp-0.30.1 6 years ago
Jonathan G Rennison 4bf4862674 Add AI/game script DoCommand calls to command log 6 years ago
Jonathan G Rennison c3e90b61b7 Merge branch 'master' into jgrpp
# Conflicts:
#	src/vehicle_cmd.cpp
6 years ago
peter1138 8114bad033 Fix #7469: Desync when using build and refit feature. 6 years ago
Patric Stout c99f731f89 Update: documentation updates from 1.9 branch 6 years ago
Jonathan G Rennison a0c8bd2164 Version: Committing version data for tag: jgrpp-0.30.0 6 years ago
Jonathan G Rennison 5de3d907a0 version_utils.sh: Allow .ottdrev-vc to be dirty at release time 6 years ago
Jonathan G Rennison 44c8696b2a Fix Win32 compilation with WITH_DBGHELP on non-MSVC 6 years ago
Jonathan G Rennison a404db80f6 Merge branch 'master' into jgrpp
# Conflicts:
#	src/town_cmd.cpp
6 years ago
Jonathan G Rennison 7b36bba766 Fix max value for zoning overlay settings 6 years ago
Jonathan G Rennison cd2b2f4c04 Add details to SettingEntry::Init assertion failure message 6 years ago
translators 24fc25164a Update: Translations from eints
french: 3 changes by glx
croatian: 17 changes by VoyagerOne
6 years ago
Jonathan G Rennison 5242ec4642 Fix handling of GRF programmable signal graphics with trace restrict 6 years ago
Niels Martin Hansen cebdd72146 Fix #7440: Remove town sign when deleting town, not add it once more 6 years ago
Jonathan G Rennison 53ff27370d Do not update viewport sign kd tree in network dedicated mode, or during savegame conversion 6 years ago
translators 92d5835495 Update: Translations from eints
dutch: 2 changes by JanWillem
french: 19 changes by glx
6 years ago