From 16f6d79f769398bbb43f99de734257115a9608ca Mon Sep 17 00:00:00 2001
From: Dave Kaprielian <sabin@lindenlab.com>
Date: Wed, 9 Apr 2008 06:12:20 +0000
Subject: [PATCH] svn merge -r83893:84415
 svn+ssh://svn.lindenlab.com/svn/linden/branches/Branch_1-20-0-Server

---
 indra/llcommon/llversionserver.h              |  2 +-
 indra/llcommon/llversionviewer.h              |  2 +-
 indra/llmath/llvolume.cpp                     | 36 ++++++++++---------
 .../lscript_compile/lscript_typecheck.cpp     |  6 ++--
 indra/newview/English.lproj/InfoPlist.strings |  4 +--
 indra/newview/Info-SecondLife.plist           |  2 +-
 6 files changed, 28 insertions(+), 24 deletions(-)

diff --git a/indra/llcommon/llversionserver.h b/indra/llcommon/llversionserver.h
index 5da3c01096b..9d98f945dde 100644
--- a/indra/llcommon/llversionserver.h
+++ b/indra/llcommon/llversionserver.h
@@ -35,7 +35,7 @@
 const S32 LL_VERSION_MAJOR = 1;
 const S32 LL_VERSION_MINOR = 20;
 const S32 LL_VERSION_PATCH = 0;
-const S32 LL_VERSION_BUILD = 83892;
+const S32 LL_VERSION_BUILD = 84396;
 
 const char * const LL_CHANNEL = "Second Life Server";
 
diff --git a/indra/llcommon/llversionviewer.h b/indra/llcommon/llversionviewer.h
index 7583bc28dd9..8e964d38916 100644
--- a/indra/llcommon/llversionviewer.h
+++ b/indra/llcommon/llversionviewer.h
@@ -35,7 +35,7 @@
 const S32 LL_VERSION_MAJOR = 1;
 const S32 LL_VERSION_MINOR = 19;
 const S32 LL_VERSION_PATCH = 1;
-const S32 LL_VERSION_BUILD = 4;
+const S32 LL_VERSION_BUILD = 84396;
 
 const char * const LL_CHANNEL = "Second Life Release";
 
diff --git a/indra/llmath/llvolume.cpp b/indra/llmath/llvolume.cpp
index 43b42bf1828..1eca954cd36 100644
--- a/indra/llmath/llvolume.cpp
+++ b/indra/llmath/llvolume.cpp
@@ -1857,7 +1857,6 @@ inline LLVector3 sculpt_rgb_to_vector(U8 r, U8 g, U8 b)
 inline U32 sculpt_xy_to_index(U32 x, U32 y, U16 sculpt_width, U16 sculpt_height, S8 sculpt_components)
 {
 	U32 index = (x + y * sculpt_width) * sculpt_components;
-
 	return index;
 }
 
@@ -3533,18 +3532,22 @@ BOOL LLVolume::cleanupTriangleData( const S32 num_input_vertices,
 									S32 **output_triangles)
 {
 	/* Testing: avoid any cleanup
-	num_output_vertices = num_input_vertices;
-	num_output_triangles = num_input_triangles;
-
-	*output_vertices = new LLVector3[num_input_vertices];
-	for (S32 i = 0; i < num_input_vertices; i++)
+	static BOOL skip_cleanup = TRUE;
+	if ( skip_cleanup )
 	{
-		(*output_vertices)[i] = input_vertices[i].mPos;
-	}
+		num_output_vertices = num_input_vertices;
+		num_output_triangles = num_input_triangles;
 
-	*output_triangles = new S32[num_input_triangles*3];
-	memcpy(*output_triangles, input_triangles, 3*num_input_triangles*sizeof(S32));		// Flawfinder: ignore
-	return TRUE;
+		*output_vertices = new LLVector3[num_input_vertices];
+		for (S32 index = 0; index < num_input_vertices; index++)
+		{
+			(*output_vertices)[index] = input_vertices[index].mPos;
+		}
+
+		*output_triangles = new S32[num_input_triangles*3];
+		memcpy(*output_triangles, input_triangles, 3*num_input_triangles*sizeof(S32));		// Flawfinder: ignore
+		return TRUE;
+	}
 	*/
 
 	// Here's how we do this:
@@ -3610,8 +3613,8 @@ BOOL LLVolume::cleanupTriangleData( const S32 num_input_vertices,
 	for (i = 0; i < num_input_triangles; i++)
 	{
 		S32 v1 = i*3;
-		S32 v2 = i*3 + 1;
-		S32 v3 = i*3 + 2;
+		S32 v2 = v1 + 1;
+		S32 v3 = v1 + 2;
 
 		//llinfos << "Checking triangle " << input_triangles[v1] << ":" << input_triangles[v2] << ":" << input_triangles[v3] << llendl;
 		input_triangles[v1] = vertex_mapping[input_triangles[v1]];
@@ -3905,16 +3908,17 @@ const F32 MIN_CONCAVE_PATH_WEDGE = 0.111111f;	// 1/9 unity
 BOOL LLVolumeParams::isConvex() const
 {
 	F32 path_length = mPathParams.getEnd() - mPathParams.getBegin();
+	F32 hollow = mProfileParams.getHollow();
 	 
-	if ( mPathParams.getTwist() != mPathParams.getTwistBegin()
-		&& path_length > MIN_CONCAVE_PATH_WEDGE )
+	if ( path_length > MIN_CONCAVE_PATH_WEDGE
+		&& ( mPathParams.getTwist() != mPathParams.getTwistBegin()
+		     || hollow > 0.f ) )
 	{
 		// twist along a "not too short" path is concave
 		return FALSE;
 	}
 
 	F32 profile_length = mProfileParams.getEnd() - mProfileParams.getBegin();
-	F32 hollow = mProfileParams.getHollow();
 	BOOL same_hole = hollow == 0.f 
 					 || (mProfileParams.getCurveType() & LL_PCODE_HOLE_MASK) == LL_PCODE_HOLE_SAME;
 
diff --git a/indra/lscript/lscript_compile/lscript_typecheck.cpp b/indra/lscript/lscript_compile/lscript_typecheck.cpp
index 847a54eb0aa..1030e8c70db 100644
--- a/indra/lscript/lscript_compile/lscript_typecheck.cpp
+++ b/indra/lscript/lscript_compile/lscript_typecheck.cpp
@@ -351,10 +351,10 @@ void init_supported_expressions(void)
 	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_INTEGER][LST_FLOATINGPOINT] = LST_FLOATINGPOINT;
 	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_FLOATINGPOINT][LST_FLOATINGPOINT] = LST_FLOATINGPOINT;
 	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_VECTOR][LST_INTEGER] = LST_VECTOR;
-	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_INTEGER][LST_VECTOR] = LST_VECTOR;
+	//gSupportedExpressionArray[LET_MUL_ASSIGN][LST_INTEGER][LST_VECTOR] = LST_VECTOR;
 	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_VECTOR][LST_FLOATINGPOINT] = LST_VECTOR;
-	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_FLOATINGPOINT][LST_VECTOR] = LST_VECTOR;
-	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_VECTOR][LST_VECTOR] = LST_FLOATINGPOINT;
+	//gSupportedExpressionArray[LET_MUL_ASSIGN][LST_FLOATINGPOINT][LST_VECTOR] = LST_VECTOR;
+	//gSupportedExpressionArray[LET_MUL_ASSIGN][LST_VECTOR][LST_VECTOR] = LST_FLOATINGPOINT;
 	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_VECTOR][LST_QUATERNION] = LST_VECTOR;
 	gSupportedExpressionArray[LET_MUL_ASSIGN][LST_QUATERNION][LST_QUATERNION] = LST_QUATERNION;
 
diff --git a/indra/newview/English.lproj/InfoPlist.strings b/indra/newview/English.lproj/InfoPlist.strings
index bb7ddc17a69..6012c011c1d 100644
--- a/indra/newview/English.lproj/InfoPlist.strings
+++ b/indra/newview/English.lproj/InfoPlist.strings
@@ -1,5 +1,5 @@
 /* Localized versions of Info.plist keys */
 
 CFBundleName = "Second Life";
-CFBundleShortVersionString = "Second Life version 1.19.1.4";
-CFBundleGetInfoString = "Second Life version 1.19.1.4, Copyright 2004-2008 Linden Research, Inc.";
+CFBundleShortVersionString = "Second Life version 1.19.1.84396";
+CFBundleGetInfoString = "Second Life version 1.19.1.84396, Copyright 2004-2008 Linden Research, Inc.";
diff --git a/indra/newview/Info-SecondLife.plist b/indra/newview/Info-SecondLife.plist
index 492e589384c..62f5ea167de 100644
--- a/indra/newview/Info-SecondLife.plist
+++ b/indra/newview/Info-SecondLife.plist
@@ -32,7 +32,7 @@
 		</dict>
 	</array>
 	<key>CFBundleVersion</key>
-	<string>1.19.1.4</string>
+	<string>1.19.1.84396</string>
 	<key>CSResourcesFileMapped</key>
 	<true/>
 </dict>
-- 
GitLab