aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/llhoverview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'linden/indra/newview/llhoverview.cpp')
-rw-r--r--linden/indra/newview/llhoverview.cpp20
1 files changed, 9 insertions, 11 deletions
diff --git a/linden/indra/newview/llhoverview.cpp b/linden/indra/newview/llhoverview.cpp
index 9c403f4..30ee2b0 100644
--- a/linden/indra/newview/llhoverview.cpp
+++ b/linden/indra/newview/llhoverview.cpp
@@ -144,7 +144,7 @@ void LLHoverView::updateHover(LLTool* current_tool)
144 else if (mStartHoverTimer.getElapsedTimeF32() > DELAY_BEFORE_SHOW_TIP) 144 else if (mStartHoverTimer.getElapsedTimeF32() > DELAY_BEFORE_SHOW_TIP)
145 { 145 {
146 gViewerWindow->hitObjectOrLandGlobalAsync(gViewerWindow->getCurrentMouseX(), 146 gViewerWindow->hitObjectOrLandGlobalAsync(gViewerWindow->getCurrentMouseX(),
147 gViewerWindow->getCurrentMouseY(), 0, pickCallback, TRUE ); 147 gViewerWindow->getCurrentMouseY(), 0, pickCallback );
148 } 148 }
149 } 149 }
150 else 150 else
@@ -214,9 +214,9 @@ void LLHoverView::resetLastHoverObject()
214 214
215void LLHoverView::updateText() 215void LLHoverView::updateText()
216{ 216{
217 char first_name[DB_FIRST_NAME_BUF_SIZE]; 217 char first_name[DB_FIRST_NAME_BUF_SIZE]; /*Flawfinder: ignore*/
218 char last_name[DB_LAST_NAME_BUF_SIZE]; 218 char last_name[DB_LAST_NAME_BUF_SIZE]; /*Flawfinder: ignore*/
219 char group_name[DB_GROUP_NAME_BUF_SIZE]; 219 char group_name[DB_GROUP_NAME_BUF_SIZE]; /*Flawfinder: ignore*/
220 220
221 LLViewerObject* hit_object = getLastHoverObject(); 221 LLViewerObject* hit_object = getLastHoverObject();
222 222
@@ -274,12 +274,10 @@ void LLHoverView::updateText()
274 // 274 //
275 BOOL suppressObjectHoverDisplay = !gSavedSettings.getBOOL("ShowAllObjectHoverTip"); 275 BOOL suppressObjectHoverDisplay = !gSavedSettings.getBOOL("ShowAllObjectHoverTip");
276 276
277 277 LLSelectNode *nodep = gSelectMgr->getHoverNode();;
278 LLSelectNodeList &nodes = gSelectMgr->getHoverObjects();
279 LLSelectNode *nodep = nodes.getFirstRootNode();
280 if (nodep) 278 if (nodep)
281 { 279 {
282 char cstring[256]; 280 char cstring[256]; /*Flawfinder: ignore*/
283 LLString *temp_str = NULL; 281 LLString *temp_str = NULL;
284 282
285 temp_str = new LLString(); 283 temp_str = new LLString();
@@ -426,7 +424,7 @@ void LLHoverView::updateText()
426 { 424 {
427 temp_str = new LLString(); 425 temp_str = new LLString();
428 temp_str->append("For Sale: "); 426 temp_str->append("For Sale: ");
429 sprintf(cstring, "L$%d", nodep->mSaleInfo.getSalePrice()); 427 snprintf(cstring, sizeof(cstring), "L$%d", nodep->mSaleInfo.getSalePrice()); /*Flawfinder: ignore*/
430 temp_str->append(cstring); 428 temp_str->append(cstring);
431 mText.addDataAtEnd(temp_str); 429 mText.addDataAtEnd(temp_str);
432 suppressObjectHoverDisplay = FALSE; // Show tip 430 suppressObjectHoverDisplay = FALSE; // Show tip
@@ -616,8 +614,8 @@ void LLHoverView::updateText()
616 */ 614 */
617 if (hover_parcel && hover_parcel->getParcelFlag(PF_FOR_SALE)) 615 if (hover_parcel && hover_parcel->getParcelFlag(PF_FOR_SALE))
618 { 616 {
619 char buffer[MAX_STRING]; 617 char buffer[MAX_STRING]; /*Flawfinder: ignore*/
620 sprintf(buffer, "For Sale: L$%d", hover_parcel->getSalePrice() ); 618 snprintf(buffer, sizeof(buffer), "For Sale: L$%d", hover_parcel->getSalePrice() ); /*Flawfinder: ignore*/
621 619
622 line = new LLString(buffer); 620 line = new LLString(buffer);
623 mText.addDataAtEnd(line); 621 mText.addDataAtEnd(line);