summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2024-07-18Improve viewer's defense against `LLEventAPI` failures.Nat Goodspeed
`LLEventAPI` is specifically intended to allow a LEAP plugin, or a Lua script, to access certain viewer functionality. Errors in external code like that cannot be addressed during viewer development. Any code path that allows external code in any form to crash the viewer opens up a potential abuse vector, if a trusting user runs external code from an untrustworthy source. `LLDispatchListener` reports exceptions back to its invoker, if the invoker provides a "reply" `LLEventPump` name. Absent "reply", though, `LLDispatchListener` is documented to let any such exception propagate. That behavior may be okay for internal use, but in the case of the `LLEventAPI` subclass, it veers into the abuse scenario described above. Make `LLEventAPI` ensure that any exception propagating from `LLDispatchListener` is caught and logged, but not propagated. Also enrich error reporting for the "batch" `LLDispatchListener` operations.
2024-07-18Ditch `LLEventTrackable` aka `boost::signals2::trackable`.Nat Goodspeed
Remove documented `LLEventPump` support for `LLEventTrackable`. That claimed support was always a little bit magical/fragile. IF: * a class included `LLEventTrackable` as a base class AND * an instance of that class was managed by `boost::shared_ptr` AND * you passed one of that class's methods and the `boost::shared_ptr` specifically to `boost::bind()` AND * the resulting `boost::bind()` object was passed into `LLEventPump::listen()` THEN the promise was that on destruction of that object, that listener would automatically be disconnected -- instead of leaving a dangling pointer bound into the `LLEventPump`, causing a crash on the next `LLEventPump::post()` call. The only existing code in the viewer code base that exercised `LLEventTrackable` functionality was in test programs. When the viewer calls `LLEventPump::listen()`, it typically stores the resulting connection object in an `LLTempBoundListener` variable, which guarantees disconnection on destruction of that variable. The fact that `LLEventTrackable` support is specific to `boost::bind()`, that it silently fails to keep its promise with `std::bind()` or a lambda or any other form of C++ callable, makes it untrustworthy for new code. Note that the code base still uses `boost::signals2::trackable` for other `boost::signals2::signal` instances not associated with `LLEventPump`. We are not changing those at this time.
2024-07-18Make `LLEventPump::listen()` also accept new `LLAwareListener`.Nat Goodspeed
`listen()` still takes `LLEventListener`, a `callable(const LLSD&)`, but now also accepts `LLAwareListener`, a `callable(const LLBoundListener&, const LLSD&)`. This uses `boost::signals2::signal::connect_extended()`, which, when the signal is called, passes to a connected listener the `LLBoundListener` (aka `boost::signals2::connection`) representing its own connection. This allows a listener to disconnect itself when done. Internally, `listen_impl()` now always uses `connect_extended()`. When passed a classic `LLEventListener`, `listen()` wraps it in a lambda that ignores the passed `LLBoundListener`. `listen()` also now accepts `LLVoidListener`, and internally wraps it in a lambda that returns `false` on its behalf.
2024-07-18viewer#2061 Crash in ~LLScriptEdCore()Andrey Kleshchev
2024-07-18viewer#1997 Warn user if closing appearance with unsaved changesAndrey Kleshchev
2024-07-18Fixes bad upload quality issue with OpenJPEG (#2054)Ayane
2024-07-18Remove unnecessary code and (re-)add some more compile time constants (#2057)Ansariel Hiller
2024-07-18#1500 Better out of disk space handlingAlexander Gavriliuk
2024-07-18Fix trailing whitespaces in webrtc code to pass pre-commitAndrey Lihatskiy
2024-07-18#2051 BugSplat Crash #1495268: LLVOAvatar::updateRiggingInfo()Alexander Gavriliuk
2024-07-18#2029 OSMessageBoxWin32 shows message box behind the viewer windowAlexander Gavriliuk
2024-07-18viewer#2027 Cannot apply PBR Materials on larger linksetsAndrey Kleshchev
Split updates into batches that respect server update limit
2024-07-17Merge remote-tracking branch 'origin/release/2024.06-atlasaurus' into developBrad Linden
# Conflicts: # autobuild.xml
2024-07-17Merge remote-tracking branch 'origin/release/webrtc-voice' into ↵Brad Linden
release/2024.06-atlasaurus # Conflicts: # autobuild.xml # indra/newview/llvoicechannel.cpp
2024-07-17Merge remote-tracking branch 'origin/release/2024.06-atlasaurus' into developBrad Linden
2024-07-17Merge remote-tracking branch 'origin/release/webrtc-voice' into developBrad Linden
# Conflicts: # autobuild.xml
2024-07-17viewer-private#251 Fixed state of folder creation in marketplaceAndrey Kleshchev
2024-07-17Lua api for adding new menu items to the Top menuMaxim Nikolenko
2024-07-17#2036 BugSplat Crash #1494874: ↵Alexander Gavriliuk
LLScrollingPanelList::updatePanelVisiblilty()(220)
2024-07-17Fix: Update calcDataSizeJ2C to pyramid-base file size estimation (#2032)TommyTheTerrible
* Fix: Update calcDataSizeJ2C to pyramid-base file size estimation Used the loop from the previous LayerFactored method to create a more accurate file size estimation by walking up the pyramid tiles. Sizes are much larger in many cases and eliminate partial decoder issues with OpenJPEG. KDU not tested but expected to produce better files as well. Should also stop decode failures on tiny or very rectangular dimensions. --------- Co-authored-by: Andrey Lihatskiy <alihatskiy@productengine.com>
2024-07-17Raised the 512x512 limitation for uploading snapshots to inventory to ↵Ayane
2048x2048 (#2025)
2024-07-16#2039 BugSplat Crash #1494687: LLPipeline::calcNearbyLights(LLCamera&)Alexander Gavriliuk
2024-07-16#2034 BugSplat Crash #1494883: LLCullResult::clear(3983)Alexander Gavriliuk
2024-07-16viewer#2006 Fixed terrain textures not updating in the "Region/Estate" floaterAndrey Kleshchev
2024-07-16viewer#1975 Fixed "Allow Land Resell" option not switchingAndrey Kleshchev
2024-07-14Fix: Stop textures from being set as inactive if still on a face. (#2017)TommyTheTerrible
Textures were being set to Inactive even if still in scene, causing them to be deleted and re-decoded in a loop.
2024-07-12viewer#1990 Fixed "Main dictionary" option is switching to the previous valueAndrey Kleshchev
2024-07-12Make image_list_t iterator const (#2010)Zi Ree
gcc complains about this iterator not being const
2024-07-12Initialize array before use (#2011)Zi Ree
gcc detects usage of this array as uninitialized, so make sure it's initialized. I am not sure if this is a legitimate warning, or if the code guarantees the array gets initialized before use in lines 140-142 and this is a performance optimization.
2024-07-12Merge pull request #2009 from secondlife/lua-llsd-debug-settingnat-goodspeed
Show description and actual value of LLSD type setting
2024-07-12fix for 'Run' buttonMnikolenko Productengine
2024-07-12Show description and actual value of LLSD type settingMnikolenko Productengine
2024-07-12viewer#1988 "Set empty" for controls ignores "Apply to all"Andrey Kleshchev
2024-07-11Merge pull request #2002 from secondlife/revert-1982-v-1885cosmic-linden
Revert "secondlife/viewer#1885: Terrain texture repeats: Remove feature flag dependency on simulator feature in favor of cap"
2024-07-11Partially revert "secondlife/viewer#1885: Terrain texture repeats: Remove ↵cosmic-linden
feature flag dependency on simulator feature in favor of cap"
2024-07-11Fix for tracy build.RunitaiLinden
2024-07-11Fix for GLTF scenes not uploading (#1994)Dave Parks
2024-07-11Merge pull request #1984 from secondlife/lua-no-reusenat-goodspeed
Remove ability to reuse a `LuaState` between `LLLUAmanager` functions.
2024-07-11viewer#1253 Viewer tries to detach attachments in inventory on shutdownAndrey Kleshchev
2024-07-11viewer#1975 Fixed "Allow Land Resell" option not switchingAndrey Kleshchev
2024-07-11Update llphysicsextensions_source to v1.0.66e6919 (#1985)Andrey Lihatskiy
2024-07-11viewer#1965 Fixed selection swirls swirling forever when the UI is hidden.Andrey Kleshchev
2024-07-11#1859 BugSplat Crash: SecondLifeViewer!<lambda>::operator()(61)Alexander Gavriliuk
2024-07-10Merge pull request #1982 from secondlife/v-1885cosmic-linden
secondlife/viewer#1885: Terrain texture repeats: Remove feature flag dependency on simulator feature in favor of cap
2024-07-10Merge branch 'lua-atexit-run' into lua-no-reuse.Nat Goodspeed
We couldn't discard the "p.s." fiber.run() call from LuaState::expr() until we could count on fiber.lua's LL.atexit(fiber.run) call being executed after each Lua script or chunk, and we couldn't count on that until we made LLLUAmanager::runScriptFile() instantiate and destroy its LuaState on the C++ Lua-specific coroutine. Now that we've done that, use LL.atexit(fiber.run) instead of the whole special-case "p.s." in LuaState::expr().
2024-07-10Remove ability to reuse a LuaState between LLLUAmanager functions.Nat Goodspeed
Remove LLLUAmanager::mumbleScriptLine() LuaState& parameters. Make startScriptLine(), waitScriptLine() and runScriptLine() exactly parallel to startScriptFile(), waitScriptFile() and runScriptFile(). That means that runScriptLine()'s C++ coroutine instantiates and destroys its own LuaState, which means that LL.atexit() functions will run on the Lua-specific C++ coroutine rather than (say) the viewer's main coroutine. Introduce LLLUAmanager::script_result typedef for std::pair<int, LLSD> and use in method returns. Remove LuaState::initLuaState(); move its logic back into the constructor. Remove initLuaState() calls in the expr() error cases: they're moot now that we won't get subsequent expr() calls on the same LuaState instance. Remove LLFloaterLUADebug "Use clean lua_State" checkbox and the cleanLuaState() method. Remove mState member. Remove explicit LuaState declarations from LLLUAmanager tests. Adapt one test for implicit LuaState: it was directly calling LuaState::obtainListener() to discover the LuaListener's reply-pump name. But since that test also captures two leap.request() calls from the Lua script, it can just look at the "reply" key in either of those requests.
2024-07-10Neither alpha, tattoo nor universal wearable edit panels contain a param ↵Ansariel Hiller
list and a main panel (#1978)
2024-07-10secondlife/viewer#1885: Update test planCosmic Linden
2024-07-10secondlife/viewer#1885: Terrain texture repeats: Remove feature flag ↵Cosmic Linden
dependency on simulator feature in favor of cap
2024-07-10Introduce LLCoros::RMutex, use for SettingsConfig::mRecorderMutex (#1980)nat-goodspeed
in llerror.cpp.