Commit Graph

51 Commits (b18f328c08a0af7032c24843cf1d045eea73ad33)

Author SHA1 Message Date
Mnikolenko Productengine 03921adb12 SL-2202 Add exception handling around boost::regex_match() calls in the viewer 2021-01-11 17:07:03 +02:00
Andrey Lihatskiy 9406b757a3 Merge branch 'DRTVWR-501-maint' into DRTVWR-503-maint
# Conflicts:
#	indra/cmake/DirectX.cmake
#	indra/newview/llviewerparcelmedia.cpp
#	indra/newview/viewer_manifest.py
2020-08-11 01:34:13 +03:00
Andrey Lihatskiy 7bbf3f5f7f Merge branch 'master' into DRTVWR-501-maint
# Conflicts:
#	autobuild.xml
#	indra/newview/llimprocessing.cpp
2020-07-20 22:24:10 +03:00
Andrey Lihatskiy 4ac0ab2af3 Merge branch 'DRTVWR-501-maint' into DRTVWR-503-maint 2020-07-06 21:48:11 +03:00
Andrey Kleshchev fa1ae9fa1a SL-13540 Fix line endings 2020-07-06 13:47:24 +03:00
Nat Goodspeed 5ab0ff486b DRTVWR-476, SL-11430: Merge branch 'SL-9756' into d476 2020-07-02 13:24:29 -04:00
Andrey Kleshchev bf5585c0ec SL-13540 Offline scripted inventory offers not shown on non drtsim-451 2020-07-02 19:05:12 +03:00
Rider Linden 766b21a0a6 SL-13533: Use the old name for from_agent_name
SL-13540: Do not fail if binary bucket is too large, attempt to extract the asset type from the old style bucket. Notification still not shown.
2020-07-02 19:05:12 +03:00
Andrey Kleshchev 7c122757f9 SL-13540 Offline scripted inventory offers not shown on non drtsim-451 2020-07-02 19:00:23 +03:00
Rider Linden 3379259ffb SL-13533: Use the old name for from_agent_name
SL-13540: Do not fail if binary bucket is too large, attempt to extract the asset type from the old style bucket. Notification still not shown.
2020-07-02 19:00:23 +03:00
Nat Goodspeed a075a73920 DRTVWR-476: Merge branch 'SL-9756' into d476. 2020-06-30 16:59:17 -04:00
Rider Linden 01f2308c85 SL-9756: Get the LLSD names right. 2020-06-30 23:13:05 +03:00
Rider Linden f72759c16d SL-9756: IM_TASK_INVENTORY_OFFERED bucket offline format conforms to the online format. 2020-06-30 23:13:05 +03:00
Rider Linden f8e53adce7 SL-9756: Get session_id/transaction id from aux if session is missing. 2020-06-30 23:13:04 +03:00
Rider Linden c8b7466c19 SL-11430, SL-9756: Take transaction-id from offline messages. Correct LLSD names. Use offline flag rather than implicit tests of session_id and aux_id. 2020-06-30 23:13:04 +03:00
Rider Linden e2dd15397c SL-9756: Take the "session_id" from the offline message that was passed. 2020-06-30 23:13:04 +03:00
Rider Linden 52f888b8d3 SL-9756: Get the LLSD names right. 2020-06-30 02:38:53 +03:00
Rider Linden 8bf2078e90 SL-9756: IM_TASK_INVENTORY_OFFERED bucket offline format conforms to the online format. 2020-06-30 02:38:53 +03:00
Rider Linden 5f9a18c88f SL-9756: Get session_id/transaction id from aux if session is missing. 2020-06-30 02:38:53 +03:00
Rider Linden 9887af162b SL-11430, SL-9756: Take transaction-id from offline messages. Correct LLSD names. Use offline flag rather than implicit tests of session_id and aux_id. 2020-06-30 02:38:53 +03:00
Rider Linden 25e6dc4adb SL-9756: Take the "session_id" from the offline message that was passed. 2020-06-30 02:38:53 +03:00
Nat Goodspeed ca6f092929 DRTVWR-476: Merge branch 'master' of lindenlab/viewer into DRTVWR-476-boost-1.72 2020-05-06 16:06:26 -04:00
Nat Goodspeed 9d5b897600 DRTVWR-494: Defend LLInstanceTracker against multi-thread usage.
The previous implementation went to some effort to crash if anyone attempted
to create or destroy an LLInstanceTracker subclass instance during traversal.
That restriction is manageable within a single thread, but becomes unworkable
if it's possible that a given subclass might be used on more than one thread.

Remove LLInstanceTracker::instance_iter, beginInstances(), endInstances(),
also key_iter, beginKeys() and endKeys(). Instead, introduce key_snapshot()
and instance_snapshot(), the only means of iterating over LLInstanceTracker
instances. (These are intended to resemble functions, but in fact the current
implementation simply presents the classes.) Iterating over a captured
snapshot defends against container modifications during traversal. The term
'snapshot' reminds the coder that a new instance created during traversal will
not be considered. To defend against instance deletion during traversal, a
snapshot stores std::weak_ptrs which it lazily dereferences, skipping on the
fly any that have expired.

Dereferencing instance_snapshot::iterator gets you a reference rather than a
pointer. Because some use cases want to delete all existing instances, add an
instance_snapshot::deleteAll() method that extracts the pointer. Those cases
used to require explicitly copying instance pointers into a separate
container; instance_snapshot() now takes care of that. It remains the caller's
responsibility to ensure that all instances of that LLInstanceTracker subclass
were allocated on the heap.

Replace unkeyed static LLInstanceTracker::getInstance(T*) -- which returned
nullptr if that instance had been destroyed -- with new getWeak() method
returning std::weak_ptr<T>. Caller must detect expiration of that weak_ptr.

Adjust tests accordingly.

Use of std::weak_ptr to detect expired instances requires engaging
std::shared_ptr in the constructor. We now store shared_ptrs in the static
containers (std::map for keyed, std::set for unkeyed).

Make LLInstanceTrackerBase a template parameterized on the type of the static
data it manages. For that reason, hoist static data class declarations out of
the class definitions to an LLInstanceTrackerStuff namespace.

Remove the static atomic sIterationNestDepth and its methods incrementDepth(),
decrementDepth() and getDepth(), since they were used only to forbid creation
and destruction during traversal.

Add a std::mutex to static data. Introduce an internal LockStatic class that
locks the mutex while providing a pointer to static data, making that the only
way to access the static data.

The LLINSTANCETRACKER_DTOR_NOEXCEPT macro goes away because we no longer
expect ~LLInstanceTracker() to throw an exception in test programs.
That affects LLTrace::StatBase as well as LLInstanceTracker itself.

Adapt consumers to the new LLInstanceTracker API.
2020-03-25 15:28:17 -04:00
Mnikolenko Productengine 6c41ea62ce SL-12871 'Only Friends and Groups can call or IM me' setting should be account based. 2020-03-19 16:14:02 +02:00
Andrey Lihatskiy a52ef7ad60 Merge branch 'DRTVWR-499' into DRTVWR-500 2020-02-03 15:13:37 +02:00
andreykproductengine a8437a7636 potential crashfix 2020-01-29 18:02:41 +02:00
AndreyL ProductEngine bc496f5f17 Downstream merge from lindenlab/viewer-lynx 2019-11-27 22:58:52 +02:00
AndreyL ProductEngine f89c9e9b20 Downstream merge from lindenlab/viewer-serval 2019-11-27 22:57:13 +02:00
AndreyL ProductEngine 216fe3d47f Merged in pe_devs/494-wassail 2019-11-27 22:36:28 +02:00
AndreyL ProductEngine 8a0338bda0 Backed out changeset: 3ea1714b65b8 2019-11-20 21:41:27 +02:00
AndreyL ProductEngine 91fa31c065 Downstream merge from lindenlab/viewer-serval 2019-11-12 04:24:35 +02:00
AndreyL ProductEngine 5f731d84cb Downstream merge from 494-maint-wassail 2019-11-12 02:37:15 +02:00
AndreyL ProductEngine 84f3b2865f Merged in lindenlab/viewer-release 2019-11-12 00:39:07 +02:00
andreykproductengine 43809e1c5c SL-12180 Crash on requestOfflineMessagesCoro 2019-10-23 22:37:59 +03:00
AndreyL ProductEngine 12baf75878 Downstream merge from lindenlab/viewer-manul 2019-10-09 19:32:19 +03:00
Rider Linden 3feba8be0d SL-11430: Transaction ID is passed as aux_id from offline message. No special parsing required to get type from binary_bucket. 2019-10-01 16:49:33 -07:00
maxim_productengine 05fcbb5df9 SL-11909 FIXED Crash in Second Life Release!LLIMProcessing::requestOfflineMessagesCoro 2019-09-10 17:55:27 +03:00
Mnikolenko Productengine 96c78187c1 SL-12129 FIXED Object IMs doesn't react to an instant message from an object. 2019-10-17 14:48:31 +03:00
Rider Linden a9a2ca0d74 SL-11430: Transaction ID is passed as aux_id from offline message. No special parsing required to get type from binary_bucket. 2019-10-01 16:49:33 -07:00
andreykproductengine 779b5627c5 DRTVWR-493 LLAvatarNameCache to singletone 2019-07-03 20:06:47 +03:00
andreykproductengine a05046f4c0 SL-11454 Exception for muted objects, such offers should get declined 2019-06-27 17:52:11 +03:00
andreykproductengine d392b97aa7 SL-11454 Dismissing group notice should move attachment to trash 2019-06-26 17:00:43 +03:00
andreykproductengine ab0d3f09d7 SL-9975 All offline inventory offers from scripted objects are lost 2018-11-14 17:15:11 +02:00
andreykproductengine dc0bd05717 SL-927 Add new groups caps to viewer (offline messages only) 2018-06-26 14:47:30 +03:00
AndreyL ProductEngine 46817fcbd3 Merged in lindenlab/viewer-lynx 2018-04-12 21:24:36 +03:00
Andrey Kleshchev 980ebf5d94 MAINT-8489 Remove/Cleanup LLIMInfo 2018-04-10 15:59:21 +00:00
Andrey Kleshchev b5d72cf657 MAINT-8203 Restore legacy name lookup 2018-04-06 14:15:11 +00:00
andreykproductengine 47f5a2f7f9 MAINT-8203 LLIMInfo crash due to capability 2018-04-02 17:32:11 +03:00
andreykproductengine eb6b389b99 MAINT-8203 Group notices processing 2018-03-27 17:22:17 +03:00
andreykproductengine fb145f4994 MAINT-8203 Fixing from_group processing in ReadOfflineMsgs cap 2018-03-24 14:48:39 +02:00