summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/llvovolume.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index 1d94e9118e..caeda3d1db 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -1796,20 +1796,19 @@ void LLVOVolume::mediaNavigateBounceBack(U8 texture_index)
bool LLVOVolume::hasMediaPermission(const LLMediaEntry* media_entry, MediaPermType perm_type)
{
- // NOTE: This logic duplicates the logic in the server (in particular, in llmediaservice.cpp).
+ // NOTE: This logic ALMOST duplicates the logic in the server (in particular, in llmediaservice.cpp).
if (NULL == media_entry ) return false; // XXX should we assert here?
- // The agent has permissions to navigate if:
- // - agent has edit permissions, or
+ // The agent has permissions if:
// - world permissions are on, or
// - group permissions are on, and agent_id is in the group, or
// - agent permissions are on, and agent_id is the owner
- if (permModify())
- {
- return true;
- }
-
+ // *NOTE: We *used* to check for modify permissions here (i.e. permissions were
+ // granted if permModify() was true). However, this doesn't make sense in the
+ // viewer: we don't want to show controls or allow interaction if the author
+ // has deemed it so. See DEV-42115.
+
U8 media_perms = (perm_type == MEDIA_PERM_INTERACT) ? media_entry->getPermsInteract() : media_entry->getPermsControl();
// World permissions