2025-07-20 10:04 CEST

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0000621Spring engineGeneralpublic2007-09-02 17:03
Reporterpbrook 
Assigned ToKloot 
PrioritynormalSeveritymajorReproducibilityalways
StatusresolvedResolutionfixed 
Product Version 
Target VersionFixed in Version 
Summary0000621: [patch] Build failure with gcc4.2
DescriptionTrying to build spring on recent Debian unstable (gcc4.2) fails with:

rts/Game/Camera/FreeController.cpp:228: error: no matching function for call to 'min(double, float)'

Attached patch fixes this by using fabsf instead of fabs.
Additional InformationThere are many other bogus-looking uses of fabs.
However these don't effect function overloading, so should be optimized to fabsf by the compiler.
TagsNo tags attached.
Checked infolog.txt for Errors
Attached Files
  • ? file icon patch (845 bytes) 2007-09-02 16:10 -
    Index: AI/Global/AAI/AAIMap.cpp
    ===================================================================
    --- AI/Global/AAI/AAIMap.cpp	(revision 4288)
    +++ AI/Global/AAI/AAIMap.cpp	(working copy)
    @@ -846,10 +846,16 @@
     			}
     		}
     
    -		hIterator += 2;
    +		if (!hStop)
    +		{
    +			hIterator += 2;
     
    -		if(hCenter - hIterator < xStart || hCenter + hIterator > xEnd)
    -			hStop = true;
    +			if(hCenter - hIterator < xStart || hCenter + hIterator > xEnd)
    +			{
    +				hStop = true;
    +				hIterator -= 2;
    +			}
    +		}
     
     		if(!hStop)
     		{
    @@ -905,10 +911,16 @@
     			}
     		}
     
    -		vIterator += 2;
    +		if (!vStop)
    +		{
    +			vIterator += 2;
     
    -		if(vCenter - vIterator < yStart || vCenter + vIterator > yEnd)
    -			vStop = true;
    +			if(vCenter - vIterator < yStart || vCenter + vIterator > yEnd)
    +			{
    +				vStop = true;
    +				vIterator -= 2;
    +			}
    +		}
     	}
     
     	return ZeroVector;
    
    ? file icon patch (845 bytes) 2007-09-02 16:10 +

-Relationships
+Relationships

-Notes

~0001211

Kloot (developer)

fixed in r4296, thank you
+Notes

-Issue History
Date Modified Username Field Change
2007-09-02 16:10 pbrook New Issue
2007-09-02 16:10 pbrook File Added: patch
2007-09-02 17:03 Kloot Note Added: 0001211
2007-09-02 17:03 Kloot Status new => resolved
2007-09-02 17:03 Kloot Resolution open => fixed
2007-09-02 17:03 Kloot Assigned To => Kloot
+Issue History