summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorAnsariel <ansariel.hiller@phoenixviewer.com>2024-06-09 16:17:03 +0200
committerAnsariel <ansariel.hiller@phoenixviewer.com>2024-06-09 16:17:03 +0200
commit9e45c1e506e0cdf8ade6136da9bbf867c93d16e6 (patch)
tree843c6a783d19133e0e05698f8e93519b89ad8fcb /indra
parent22d3ea34f29bc11f3e5bfe491f4bc0895e1d4653 (diff)
Fix issues resulting from b42f9d836b4c0f7fbd4bdae1734021e2a09fdbe8
Diffstat (limited to 'indra')
-rw-r--r--indra/llappearance/llpolymorph.cpp2
-rw-r--r--indra/llui/llresmgr.cpp2
-rw-r--r--indra/llui/lltextparser.cpp2
-rw-r--r--indra/newview/llappearancemgr.cpp2
-rw-r--r--indra/newview/llfriendcard.cpp6
-rw-r--r--indra/newview/llimview.cpp2
-rw-r--r--indra/newview/llinventorybridge.cpp2
-rw-r--r--indra/newview/llinventorygallery.cpp4
-rw-r--r--indra/newview/llpanelteleporthistory.cpp6
-rw-r--r--indra/newview/llreflectionmapmanager.cpp2
-rw-r--r--indra/newview/llvograss.cpp2
-rw-r--r--indra/newview/llvopartgroup.cpp2
-rw-r--r--indra/newview/llvovolume.cpp2
13 files changed, 18 insertions, 18 deletions
diff --git a/indra/llappearance/llpolymorph.cpp b/indra/llappearance/llpolymorph.cpp
index 068be84441..7deb943a9b 100644
--- a/indra/llappearance/llpolymorph.cpp
+++ b/indra/llappearance/llpolymorph.cpp
@@ -385,7 +385,7 @@ bool LLPolyMorphTarget::setInfo(LLPolyMorphTargetInfo* info)
{
const std::string driven_tag = "_Driven";
auto pos = morph_param_name.find(driven_tag);
- if (pos > 0)
+ if (pos != std::string::npos)
{
morph_param_name = morph_param_name.substr(0,pos);
mMorphData = mMesh->getMorphData(morph_param_name);
diff --git a/indra/llui/llresmgr.cpp b/indra/llui/llresmgr.cpp
index 21bdf3f8a6..111c732548 100644
--- a/indra/llui/llresmgr.cpp
+++ b/indra/llui/llresmgr.cpp
@@ -140,7 +140,7 @@ std::string LLResMgr::getMonetaryString( S32 input ) const
S32 output_pos = 0;
cur_group = 0;
- auto pos = digits.size()-1;
+ S32 pos = static_cast<S32>(digits.size()) - 1;
S32 count_within_group = 0;
while( (pos >= 0) && (groupings[cur_group] >= 0) )
{
diff --git a/indra/llui/lltextparser.cpp b/indra/llui/lltextparser.cpp
index 6a867fc759..097b168106 100644
--- a/indra/llui/lltextparser.cpp
+++ b/indra/llui/lltextparser.cpp
@@ -74,7 +74,7 @@ S32 LLTextParser::findPattern(const std::string &text, LLSD highlight)
break;
case ENDS_WITH:
auto pos = ltext.rfind(pattern);
- if (pos >= 0 && (ltext.length()-pattern.length()==pos)) found = pos;
+ if (pos != std::string::npos && pos >= 0 && (ltext.length() - pattern.length() == pos)) found = pos;
break;
}
return static_cast<S32>(found);
diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp
index ff834a16b6..9dd23a5319 100644
--- a/indra/newview/llappearancemgr.cpp
+++ b/indra/newview/llappearancemgr.cpp
@@ -1374,7 +1374,7 @@ static void removeDuplicateItems(LLInventoryModel::item_array_t& items)
// encountered, so we actually keep the *last* of each duplicate
// item. This is needed to give the right priority when adding
// duplicate items to an existing outfit.
- for (auto i=items.size()-1; i>=0; i--)
+ for (S32 i = static_cast<S32>(items.size()) - 1; i >= 0; i--)
{
LLViewerInventoryItem *item = items.at(i);
LLUUID item_id = item->getLinkedUUID();
diff --git a/indra/newview/llfriendcard.cpp b/indra/newview/llfriendcard.cpp
index f9252e0062..5300627cec 100644
--- a/indra/newview/llfriendcard.cpp
+++ b/indra/newview/llfriendcard.cpp
@@ -244,7 +244,7 @@ bool LLFriendCardsManager::isObjDirectDescendentOfCategory(const LLInventoryObje
{
LLUUID creator_id = item->getCreatorUUID();
LLViewerInventoryItem* cur_item = NULL;
- for ( auto i = items->size() - 1; i >= 0; --i )
+ for (S32 i = static_cast<S32>(items->size()) - 1; i >= 0; --i)
{
cur_item = items->at(i);
if ( creator_id == cur_item->getCreatorUUID() )
@@ -261,7 +261,7 @@ bool LLFriendCardsManager::isObjDirectDescendentOfCategory(const LLInventoryObje
// Note: UUID's of compared items also may be not equal.
std::string obj_name = obj->getName();
LLViewerInventoryItem* cur_item = NULL;
- for ( auto i = items->size() - 1; i >= 0; --i )
+ for (S32 i = static_cast<S32>(items->size()) - 1; i >= 0; --i)
{
cur_item = items->at(i);
if ( obj->getType() != cur_item->getType() )
@@ -281,7 +281,7 @@ bool LLFriendCardsManager::isObjDirectDescendentOfCategory(const LLInventoryObje
// then return true. Note: UUID's of compared items also may be not equal.
std::string obj_name = obj->getName();
LLViewerInventoryCategory* cur_cat = NULL;
- for ( auto i = cats->size() - 1; i >= 0; --i )
+ for (S32 i = static_cast<S32>(cats->size()) - 1; i >= 0; --i)
{
cur_cat = cats->at(i);
if ( obj->getType() != cur_cat->getType() )
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index 667d11e194..7ed10b062c 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -1504,7 +1504,7 @@ void LLIMModel::getMessagesSilently(const LLUUID& session_id, chat_message_list_
return;
}
- auto i = session->mMsgs.size() - start_index;
+ int i = static_cast<int>(session->mMsgs.size()) - start_index;
for (chat_message_list_t::iterator iter = session->mMsgs.begin();
iter != session->mMsgs.end() && i > 0;
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 36df29f6d1..a6b4d62e82 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -2509,7 +2509,7 @@ bool LLFolderBridge::isClipboardPasteable() const
// Search for the direct descendent of current Friends subfolder among all pasted items,
// and return false if is found.
- for(auto i = objects.size() - 1; i >= 0; --i)
+ for (S32 i = static_cast<S32>(objects.size()) - 1; i >= 0; --i)
{
const LLUUID &obj_id = objects.at(i);
if ( LLFriendCardsManager::instance().isObjDirectDescendentOfCategory(model->getObject(obj_id), current_cat) )
diff --git a/indra/newview/llinventorygallery.cpp b/indra/newview/llinventorygallery.cpp
index a72f669189..20a4a8f2d6 100644
--- a/indra/newview/llinventorygallery.cpp
+++ b/indra/newview/llinventorygallery.cpp
@@ -257,8 +257,8 @@ void LLInventoryGallery::updateRootFolder()
{
updateRemovedItem(mItems[i]->getUUID());
}
- auto hidden_count = mHiddenItems.size();
- for (size_t i = hidden_count - 1; i >= 0; i--)
+ S32 hidden_count = static_cast<S32>(mHiddenItems.size());
+ for (S32 i = hidden_count - 1; i >= 0; i--)
{
updateRemovedItem(mHiddenItems[i]->getUUID());
}
diff --git a/indra/newview/llpanelteleporthistory.cpp b/indra/newview/llpanelteleporthistory.cpp
index 48bbb891b2..902412d359 100644
--- a/indra/newview/llpanelteleporthistory.cpp
+++ b/indra/newview/llpanelteleporthistory.cpp
@@ -743,7 +743,7 @@ void LLTeleportHistoryPanel::refresh()
break;
}
- for (size_t n = mItemContainers.size() - 1; n >= 0; --n)
+ for (S32 n = static_cast<S32>(mItemContainers.size()) - 1; n >= 0; --n)
{
LLAccordionCtrlTab* tab = mItemContainers.at(n);
LLFlatListView* fv = getFlatListViewFromTab(tab);
@@ -805,7 +805,7 @@ void LLTeleportHistoryPanel::replaceItem(S32 removed_index)
// Index of each item, from last to removed item should be decremented
// to point to the right item in LLTeleportHistoryStorage
- for (auto tab_idx = mItemContainers.size() - 1; tab_idx >= 0; --tab_idx)
+ for (S32 tab_idx = static_cast<S32>(mItemContainers.size()) - 1; tab_idx >= 0; --tab_idx)
{
LLAccordionCtrlTab* tab = mItemContainers.at(tab_idx);
if (!tab->getVisible())
@@ -859,7 +859,7 @@ void LLTeleportHistoryPanel::showTeleportHistory()
mCurrentItem = static_cast<S32>(mTeleportHistory->getItems().size()) - 1;
- for (auto n = mItemContainers.size() - 1; n >= 0; --n)
+ for (S32 n = static_cast<S32>(mItemContainers.size()) - 1; n >= 0; --n)
{
LLAccordionCtrlTab* tab = mItemContainers.at(n);
if (tab)
diff --git a/indra/newview/llreflectionmapmanager.cpp b/indra/newview/llreflectionmapmanager.cpp
index decf640bcf..aae7918ef0 100644
--- a/indra/newview/llreflectionmapmanager.cpp
+++ b/indra/newview/llreflectionmapmanager.cpp
@@ -699,7 +699,7 @@ void LLReflectionMapManager::updateProbeFace(LLReflectionMap* probe, U32 face)
res /= 2;
- GLint mip = static_cast<GLint>(i - (mMipChain.size() - mips));
+ GLint mip = i - (static_cast<GLint>(mMipChain.size()) - mips);
if (mip >= 0)
{
diff --git a/indra/newview/llvograss.cpp b/indra/newview/llvograss.cpp
index e0a818d84e..e04bdbf1d9 100644
--- a/indra/newview/llvograss.cpp
+++ b/indra/newview/llvograss.cpp
@@ -696,7 +696,7 @@ void LLGrassPartition::getGeometry(LLSpatialGroup* group)
vertex_count += facep->getGeomCount();
index_count += facep->getIndicesCount();
- auto idx = draw_vec.size()-1;
+ S32 idx = static_cast<S32>(draw_vec.size()) - 1;
bool fullbright = facep->isState(LLFace::FULLBRIGHT);
diff --git a/indra/newview/llvopartgroup.cpp b/indra/newview/llvopartgroup.cpp
index ebb7508a71..81f16cf8cb 100644
--- a/indra/newview/llvopartgroup.cpp
+++ b/indra/newview/llvopartgroup.cpp
@@ -899,7 +899,7 @@ void LLParticlePartition::getGeometry(LLSpatialGroup* group)
llassert(facep->getGeomCount() == 4);
llassert(facep->getIndicesCount() == 6);
- auto idx = draw_vec.size()-1;
+ S32 idx = static_cast<S32>(draw_vec.size()) - 1;
bool fullbright = facep->isState(LLFace::FULLBRIGHT);
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index a908bb455a..91da88f7bf 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -5199,7 +5199,7 @@ void LLVolumeGeometryManager::registerFace(LLSpatialGroup* group, LLFace* facep,
//add face to drawmap
LLSpatialGroup::drawmap_elem_t& draw_vec = group->mDrawMap[passType];
- auto idx = draw_vec.size()-1;
+ S32 idx = static_cast<S32>(draw_vec.size()) - 1;
bool fullbright = (type == LLRenderPass::PASS_FULLBRIGHT) ||
(type == LLRenderPass::PASS_INVISIBLE) ||