From 11e9fbefeb11f4ed90e22e7f0a0558442317875e Mon Sep 17 00:00:00 2001
From: Brad Kittenbrink <brad@lindenlab.com>
Date: Thu, 2 Apr 2020 10:55:31 -0700
Subject: [PATCH] Fixed -Wstring-plus-int related errors for compatibility with
 Xcode-11.4

---
 indra/llcommon/llsdutil.cpp        | 2 +-
 indra/newview/llcommandhandler.cpp | 2 +-
 indra/newview/llxmlrpclistener.cpp | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/indra/llcommon/llsdutil.cpp b/indra/llcommon/llsdutil.cpp
index 6a23c443a04..1f8384f4155 100644
--- a/indra/llcommon/llsdutil.cpp
+++ b/indra/llcommon/llsdutil.cpp
@@ -506,7 +506,7 @@ struct Data
     const char* name;
 } typedata[] =
 {
-#define def(type) { LLSD::type, #type + 4 }
+#define def(type) { LLSD::type, &#type[4] }
     def(TypeUndefined),
     def(TypeBoolean),
     def(TypeInteger),
diff --git a/indra/newview/llcommandhandler.cpp b/indra/newview/llcommandhandler.cpp
index 76d965b1f15..23e2271eae5 100644
--- a/indra/newview/llcommandhandler.cpp
+++ b/indra/newview/llcommandhandler.cpp
@@ -222,7 +222,7 @@ struct symbol_info
 
 #define ent(SYMBOL)										\
 	{													\
-		#SYMBOL + 28, /* skip "LLCommandHandler::UNTRUSTED_" prefix */	\
+		&#SYMBOL[28], /* skip "LLCommandHandler::UNTRUSTED_" prefix */	\
 		SYMBOL											\
 	}
 
diff --git a/indra/newview/llxmlrpclistener.cpp b/indra/newview/llxmlrpclistener.cpp
index 0693d08dfbb..0daf3e761d5 100644
--- a/indra/newview/llxmlrpclistener.cpp
+++ b/indra/newview/llxmlrpclistener.cpp
@@ -100,7 +100,7 @@ class CURLcodeMapper: public StatusMapperBase<CURLcode>
     {
         // from curl.h
 // skip the "CURLE_" prefix for each of these strings
-#define def(sym) (mMap[sym] = #sym + 6)
+#define def(sym) (mMap[sym] = &#sym[6])
         def(CURLE_OK);
         def(CURLE_UNSUPPORTED_PROTOCOL);    /* 1 */
         def(CURLE_FAILED_INIT);             /* 2 */
-- 
GitLab