From 3096103682304690d58970e41e1832d3acc34c0f Mon Sep 17 00:00:00 2001 From: tobigun Date: Fri, 8 Aug 2008 12:10:55 +0000 Subject: warnings suppressed git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1235 b956fd51-792f-4845-bead-9b4dfca2ff2c --- Game/Code/Classes/UCommon.pas | 4 ++++ Game/Code/Classes/UMain.pas | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'Game') diff --git a/Game/Code/Classes/UCommon.pas b/Game/Code/Classes/UCommon.pas index 7eefedac..89b5623f 100644 --- a/Game/Code/Classes/UCommon.pas +++ b/Game/Code/Classes/UCommon.pas @@ -736,6 +736,7 @@ type * supports an alignment "x" of up to 8 bytes only whereas FPC supports * alignments on 16 and 32 byte boundaries too. *) +{$WARNINGS OFF} function GetAlignedMem(Size: cardinal; Alignment: integer): Pointer; var OrigPtr: Pointer; @@ -766,12 +767,15 @@ begin // set header with info on old pointer for FreeMem PMemAlignHeader(PtrUInt(Result) - SizeOf(TMemAlignHeader))^ := OrigPtr; end; +{$WARNINGS ON} +{$WARNINGS OFF} procedure FreeAlignedMem(P: Pointer); begin if (P <> nil) then FreeMem(PMemAlignHeader(PtrUInt(P) - SizeOf(TMemAlignHeader))^); end; +{$WARNINGS ON} initialization diff --git a/Game/Code/Classes/UMain.pas b/Game/Code/Classes/UMain.pas index 7e403b22..135113b5 100644 --- a/Game/Code/Classes/UMain.pas +++ b/Game/Code/Classes/UMain.pas @@ -984,6 +984,7 @@ procedure InitializePaths; // Initialize a path variable // After setting paths, make sure that paths exist + {$WARN SYMBOL_PLATFORM OFF} function initialize_path( out aPathVar : string; const aLocation : string ): boolean; var lWriteable: Boolean; @@ -1002,12 +1003,13 @@ procedure InitializePaths; lWriteable := (lAttrib and faDirectory <> 0) and not (lAttrib and faReadOnly <> 0) end; - + if not lWriteable then Log.LogError('Dir ('+ aLocation +') is Readonly', 'initialize_path'); result := lWriteable; end; + {$WARN SYMBOL_PLATFORM ON} begin initialize_path( LogPath , Platform.GetLogPath ); -- cgit v1.2.3