From 02b7e7ce07948a25bc1f58fdbfe3499dc917340f Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Mon, 17 Aug 2015 16:08:44 -0700 Subject: Adding llcorehttp to links --- indra/llui/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'indra/llui') diff --git a/indra/llui/CMakeLists.txt b/indra/llui/CMakeLists.txt index 52738aeb6f..282df98974 100755 --- a/indra/llui/CMakeLists.txt +++ b/indra/llui/CMakeLists.txt @@ -269,6 +269,7 @@ add_library (llui ${llui_SOURCE_FILES}) # Sort by high-level to low-level target_link_libraries(llui ${LLMESSAGE_LIBRARIES} + ${LLCOREHTTP_LIBRARIES} ${LLRENDER_LIBRARIES} ${LLWINDOW_LIBRARIES} ${LLIMAGE_LIBRARIES} @@ -289,6 +290,6 @@ if(LL_TESTS) ) LL_ADD_PROJECT_UNIT_TESTS(llui "${llui_TEST_SOURCE_FILES}") # INTEGRATION TESTS - set(test_libs llui llmessage llcommon ${LLCOMMON_LIBRARIES} ${WINDOWS_LIBRARIES}) + set(test_libs llui llmessage llcorehttp llcommon ${LLCOMMON_LIBRARIES} ${WINDOWS_LIBRARIES}) LL_ADD_INTEGRATION_TEST(llurlentry llurlentry.cpp "${test_libs}") endif(LL_TESTS) -- cgit v1.2.3 From 62527e6f18f0a035a234cf584e31f7eea93fd4a7 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 18 Aug 2015 17:05:29 -0400 Subject: MAINT-5506: Fix ugly timing bug in llurlentry static initialization. The problem was that class-static LLUrlEntryParcel::sRegionHost was being initialized by copying class-static LLHost::invalid. Naturally, these two statics are initialized in different source files. Since C++ makes no promises about the relative order in which objects in different object files are initialized, it seems we hit a case in which we were trying to initialize sRegionHost by copying a completely uninitialized LLHost::invalid. In general we might attempt to address such cross-translation-unit issues by introducing an LLSingleton. But in this particular case, the punch line is that LLHost::invalid is explicitly constructed identically to a default-constructed LLHost! In other words, LLHost::invalid provides nothing we couldn't get from LLHost(). All it gives us is an opportunity for glitches such as the above. Remove LLHost::invalid and all references, replacing with LLHost(). --- indra/llui/llurlentry.cpp | 4 ++-- indra/llui/tests/llurlentry_stub.cpp | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp index 6db0d88998..adefae6e2d 100755 --- a/indra/llui/llurlentry.cpp +++ b/indra/llui/llurlentry.cpp @@ -957,7 +957,7 @@ std::string LLUrlEntryObjectIM::getLocation(const std::string &url) const // LLUrlEntryParcel statics. LLUUID LLUrlEntryParcel::sAgentID(LLUUID::null); LLUUID LLUrlEntryParcel::sSessionID(LLUUID::null); -LLHost LLUrlEntryParcel::sRegionHost(LLHost::invalid); +LLHost LLUrlEntryParcel::sRegionHost; bool LLUrlEntryParcel::sDisconnected(false); std::set LLUrlEntryParcel::sParcelInfoObservers; @@ -1006,7 +1006,7 @@ std::string LLUrlEntryParcel::getLabel(const std::string &url, const LLUrlLabelC void LLUrlEntryParcel::sendParcelInfoRequest(const LLUUID& parcel_id) { - if (sRegionHost == LLHost::invalid || sDisconnected) return; + if (sRegionHost == LLHost() || sDisconnected) return; LLMessageSystem *msg = gMessageSystem; msg->newMessage("ParcelInfoRequest"); diff --git a/indra/llui/tests/llurlentry_stub.cpp b/indra/llui/tests/llurlentry_stub.cpp index 5d3f9ac327..f01178c374 100755 --- a/indra/llui/tests/llurlentry_stub.cpp +++ b/indra/llui/tests/llurlentry_stub.cpp @@ -165,8 +165,6 @@ LLFontGL* LLFontGL::getFontDefault() char const* const _PREHASH_AgentData = (char *)"AgentData"; char const* const _PREHASH_AgentID = (char *)"AgentID"; -LLHost LLHost::invalid(INVALID_PORT,INVALID_HOST_IP_ADDRESS); - LLMessageSystem* gMessageSystem = NULL; // -- cgit v1.2.3 From f96237c963665201b01e565db4c69e6ca9a8c8f1 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 18 Aug 2015 15:18:09 -0700 Subject: Move the CoreHTTP libraries down --- indra/llui/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/CMakeLists.txt b/indra/llui/CMakeLists.txt index 282df98974..95cf32ee4a 100755 --- a/indra/llui/CMakeLists.txt +++ b/indra/llui/CMakeLists.txt @@ -268,12 +268,12 @@ add_library (llui ${llui_SOURCE_FILES}) # Libraries on which this library depends, needed for Linux builds # Sort by high-level to low-level target_link_libraries(llui - ${LLMESSAGE_LIBRARIES} - ${LLCOREHTTP_LIBRARIES} ${LLRENDER_LIBRARIES} ${LLWINDOW_LIBRARIES} ${LLIMAGE_LIBRARIES} ${LLINVENTORY_LIBRARIES} + ${LLMESSAGE_LIBRARIES} + ${LLCOREHTTP_LIBRARIES} ${LLVFS_LIBRARIES} # ugh, just for LLDir ${LLXUIXML_LIBRARIES} ${LLXML_LIBRARIES} -- cgit v1.2.3 From 250d94316b809bb94f42fec3896940e5c7da41ca Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Wed, 19 Aug 2015 11:29:47 -0700 Subject: Keep hunting these down. --- indra/llui/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/llui') diff --git a/indra/llui/CMakeLists.txt b/indra/llui/CMakeLists.txt index 95cf32ee4a..e2bbbb8285 100755 --- a/indra/llui/CMakeLists.txt +++ b/indra/llui/CMakeLists.txt @@ -290,6 +290,6 @@ if(LL_TESTS) ) LL_ADD_PROJECT_UNIT_TESTS(llui "${llui_TEST_SOURCE_FILES}") # INTEGRATION TESTS - set(test_libs llui llmessage llcorehttp llcommon ${LLCOMMON_LIBRARIES} ${WINDOWS_LIBRARIES}) + set(test_libs llui llmessage llcorehttp llcommon ${LLCOMMON_LIBRARIES} ${BOOST_COROUTINE_LIBRARY} ${BOOST_CONTEXT_LIBRARY} ${BOOST_SYSTEM_LIBRARY} ${WINDOWS_LIBRARIES}) LL_ADD_INTEGRATION_TEST(llurlentry llurlentry.cpp "${test_libs}") endif(LL_TESTS) -- cgit v1.2.3 From d3c2ab581763586718bc0cd86d6935bb46dc9d10 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Wed, 19 Aug 2015 12:39:51 -0700 Subject: Be sure the correct include is included. --- indra/llui/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/llui') diff --git a/indra/llui/CMakeLists.txt b/indra/llui/CMakeLists.txt index e2bbbb8285..259fbde806 100755 --- a/indra/llui/CMakeLists.txt +++ b/indra/llui/CMakeLists.txt @@ -8,6 +8,7 @@ include(LLImage) include(LLInventory) include(LLMath) include(LLMessage) +include(LLCoreHttp) include(LLRender) include(LLWindow) include(LLVFS) -- cgit v1.2.3 From 7c61728b4bae928b2461f0f933dd1c1fa34ef0aa Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Mon, 24 Aug 2015 14:19:30 -0700 Subject: MAINT-4952: Removed a bit of debug code that got included accidentally and change host == LLHost() to host.isInvalid() --- indra/llui/llurlentry.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/llui') diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp index adefae6e2d..eb7f98e618 100755 --- a/indra/llui/llurlentry.cpp +++ b/indra/llui/llurlentry.cpp @@ -1006,7 +1006,7 @@ std::string LLUrlEntryParcel::getLabel(const std::string &url, const LLUrlLabelC void LLUrlEntryParcel::sendParcelInfoRequest(const LLUUID& parcel_id) { - if (sRegionHost == LLHost() || sDisconnected) return; + if (sRegionHost.isInvalid() || sDisconnected) return; LLMessageSystem *msg = gMessageSystem; msg->newMessage("ParcelInfoRequest"); -- cgit v1.2.3 From 96e343b49b0b5a0951ffab0beb2e1d09c37bbdc5 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 1 Sep 2015 16:13:52 -0700 Subject: MAINT-5575: Convert the Experience cache into a coro based singleton. --HG-- branch : MAINT-5575 --- indra/llui/CMakeLists.txt | 2 ++ indra/llui/llurlentry.cpp | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/CMakeLists.txt b/indra/llui/CMakeLists.txt index 259fbde806..d192aac448 100755 --- a/indra/llui/CMakeLists.txt +++ b/indra/llui/CMakeLists.txt @@ -11,11 +11,13 @@ include(LLMessage) include(LLCoreHttp) include(LLRender) include(LLWindow) +include(LLCoreHttp) include(LLVFS) include(LLXML) include_directories( ${LLCOMMON_INCLUDE_DIRS} + ${LLCOREHTTP_INCLUDE_DIRS} ${LLIMAGE_INCLUDE_DIRS} ${LLINVENTORY_INCLUDE_DIRS} ${LLMATH_INCLUDE_DIRS} diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp index eb7f98e618..e76f2a1550 100755 --- a/indra/llui/llurlentry.cpp +++ b/indra/llui/llurlentry.cpp @@ -1430,7 +1430,7 @@ std::string LLUrlEntryExperienceProfile::getLabel( const std::string &url, const return LLTrans::getString("ExperienceNameNull"); } - const LLSD& experience_details = LLExperienceCache::get(experience_id); + const LLSD& experience_details = LLExperienceCache::getInstance()->get(experience_id); if(!experience_details.isUndefined()) { std::string experience_name_string = experience_details[LLExperienceCache::NAME].asString(); @@ -1438,7 +1438,7 @@ std::string LLUrlEntryExperienceProfile::getLabel( const std::string &url, const } addObserver(experience_id_string, url, cb); - LLExperienceCache::get(experience_id, boost::bind(&LLUrlEntryExperienceProfile::onExperienceDetails, this, _1)); + LLExperienceCache::getInstance()->get(experience_id, boost::bind(&LLUrlEntryExperienceProfile::onExperienceDetails, this, _1)); return LLTrans::getString("LoadingData"); } -- cgit v1.2.3 From f0d911817369a4c5c55224df7021a0306b104990 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 1 Sep 2015 17:03:08 -0700 Subject: One of the tests defined a namespace in order to fake out the libraries. Removed it. --- indra/llui/tests/llurlentry_test.cpp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/tests/llurlentry_test.cpp b/indra/llui/tests/llurlentry_test.cpp index 15f2354552..ba1cc436f9 100755 --- a/indra/llui/tests/llurlentry_test.cpp +++ b/indra/llui/tests/llurlentry_test.cpp @@ -37,17 +37,17 @@ #include -namespace LLExperienceCache -{ - const LLSD& get( const LLUUID& key) - { - static LLSD boo; - return boo; - } - - void get( const LLUUID& key, callback_slot_t slot ){} - -} +// namespace LLExperienceCache +// { +// const LLSD& get( const LLUUID& key) +// { +// static LLSD boo; +// return boo; +// } +// +// void get( const LLUUID& key, callback_slot_t slot ){} +// +// } typedef std::map settings_map_t; settings_map_t LLUI::sSettingGroups; -- cgit v1.2.3 From c5dc9b1a572f00e69b9cd3b5853f0a3d104af20f Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 1 Sep 2015 21:31:16 -0700 Subject: In Linux build skip url entry test --- indra/llui/CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'indra/llui') diff --git a/indra/llui/CMakeLists.txt b/indra/llui/CMakeLists.txt index d192aac448..7fb1db15fb 100755 --- a/indra/llui/CMakeLists.txt +++ b/indra/llui/CMakeLists.txt @@ -282,6 +282,7 @@ target_link_libraries(llui ${LLXML_LIBRARIES} ${LLMATH_LIBRARIES} ${HUNSPELL_LIBRARY} + ${LLMESSAGE_LIBRARIES} ${LLCOMMON_LIBRARIES} # must be after llimage, llwindow, llrender ) @@ -294,5 +295,7 @@ if(LL_TESTS) LL_ADD_PROJECT_UNIT_TESTS(llui "${llui_TEST_SOURCE_FILES}") # INTEGRATION TESTS set(test_libs llui llmessage llcorehttp llcommon ${LLCOMMON_LIBRARIES} ${BOOST_COROUTINE_LIBRARY} ${BOOST_CONTEXT_LIBRARY} ${BOOST_SYSTEM_LIBRARY} ${WINDOWS_LIBRARIES}) - LL_ADD_INTEGRATION_TEST(llurlentry llurlentry.cpp "${test_libs}") + if(NOT LINUX) + LL_ADD_INTEGRATION_TEST(llurlentry llurlentry.cpp "${test_libs}") + endif(NOT LINUX) endif(LL_TESTS) -- cgit v1.2.3 From 8913ed6692fddc5d72ee01ecb92a21093c5d22ad Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Thu, 3 Sep 2015 16:59:00 -0700 Subject: Changes from code review with Nat --- indra/llui/llurlentry.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp index e76f2a1550..72ff89f33c 100755 --- a/indra/llui/llurlentry.cpp +++ b/indra/llui/llurlentry.cpp @@ -1430,7 +1430,7 @@ std::string LLUrlEntryExperienceProfile::getLabel( const std::string &url, const return LLTrans::getString("ExperienceNameNull"); } - const LLSD& experience_details = LLExperienceCache::getInstance()->get(experience_id); + const LLSD& experience_details = LLExperienceCache::instance().get(experience_id); if(!experience_details.isUndefined()) { std::string experience_name_string = experience_details[LLExperienceCache::NAME].asString(); @@ -1438,7 +1438,7 @@ std::string LLUrlEntryExperienceProfile::getLabel( const std::string &url, const } addObserver(experience_id_string, url, cb); - LLExperienceCache::getInstance()->get(experience_id, boost::bind(&LLUrlEntryExperienceProfile::onExperienceDetails, this, _1)); + LLExperienceCache::instance().get(experience_id, boost::bind(&LLUrlEntryExperienceProfile::onExperienceDetails, this, _1)); return LLTrans::getString("LoadingData"); } -- cgit v1.2.3