(svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values
This commit is contained in:
@@ -15,6 +15,8 @@
|
||||
#include "ai_config.hpp"
|
||||
#include "ai_info.hpp"
|
||||
|
||||
#include "../safeguards.h"
|
||||
|
||||
/** Configuration for AI start date, every AI has this setting. */
|
||||
ScriptConfigItem _start_date_config = {
|
||||
"start_date",
|
||||
|
@@ -22,6 +22,8 @@
|
||||
#include "ai_info.hpp"
|
||||
#include "ai.hpp"
|
||||
|
||||
#include "../safeguards.h"
|
||||
|
||||
/* static */ uint AI::frame_counter = 0;
|
||||
/* static */ AIScannerInfo *AI::scanner_info = NULL;
|
||||
/* static */ AIScannerLibrary *AI::scanner_library = NULL;
|
||||
|
@@ -40,11 +40,12 @@
|
||||
#include "../game/game_info.hpp"
|
||||
#include "../game/game_instance.hpp"
|
||||
|
||||
|
||||
#include "table/strings.h"
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include "../safeguards.h"
|
||||
|
||||
static ScriptConfig *GetConfig(CompanyID slot)
|
||||
{
|
||||
if (slot == OWNER_DEITY) return GameConfig::GetConfig();
|
||||
|
@@ -17,6 +17,8 @@
|
||||
#include "../debug.h"
|
||||
#include "../rev.h"
|
||||
|
||||
#include "../safeguards.h"
|
||||
|
||||
/**
|
||||
* Check if the API version provided by the AI is supported.
|
||||
* @param api_version The API version as provided by the AI.
|
||||
|
@@ -82,6 +82,8 @@
|
||||
#include "../company_base.h"
|
||||
#include "../company_func.h"
|
||||
|
||||
#include "../safeguards.h"
|
||||
|
||||
AIInstance::AIInstance() :
|
||||
ScriptInstance("AI")
|
||||
{}
|
||||
|
@@ -18,6 +18,8 @@
|
||||
#include "ai_info.hpp"
|
||||
#include "ai_scanner.hpp"
|
||||
|
||||
#include "../safeguards.h"
|
||||
|
||||
|
||||
AIScannerInfo::AIScannerInfo() :
|
||||
ScriptScanner(),
|
||||
|
Reference in New Issue
Block a user