Merge Firestorm LGPL

Tue, 27 Feb 2018 18:13:33 +0100

author
Ansariel
date
Tue, 27 Feb 2018 18:13:33 +0100
changeset 55307
7087dc97640e
parent 55306
3347d1abe4f0
parent 54840
a17db93f9834
child 55308
b0549f776466

Merge Firestorm LGPL

autobuild.xml file | annotate | diff | revisions
indra/llui/lllineeditor.cpp file | annotate | diff | revisions
indra/llui/llscrolllistctrl.cpp file | annotate | diff | revisions
indra/llvfs/lldir_win32.cpp file | annotate | diff | revisions
indra/newview/llappearancemgr.cpp file | annotate | diff | revisions
indra/newview/llappviewer.cpp file | annotate | diff | revisions
indra/newview/skins/default/xui/en/notifications.xml file | annotate | diff | revisions
     1.1 --- a/autobuild.xml	Tue Feb 27 18:10:09 2018 +0100
     1.2 +++ b/autobuild.xml	Tue Feb 27 18:13:33 2018 +0100
     1.3 @@ -952,7 +952,7 @@
     1.4                <key>hash_algorithm</key>
     1.5                <string>md5</string>
     1.6                <key>url</key>
     1.7 -              <string>file:///opt/firestorm/fmodstudio-1.10.02-darwin-.tar.bz2</string>
     1.8 +              <string>file:///opt/firestorm/fmodstudio-1.10.03-darwin-.tar.bz2</string>
     1.9              </map>
    1.10              <key>name</key>
    1.11              <string>darwin</string>
    1.12 @@ -990,18 +990,18 @@
    1.13              <key>archive</key>
    1.14              <map>
    1.15                <key>hash</key>
    1.16 -              <string>206f34d4a262a09323bc9d03cd81a2f6</string>
    1.17 +              <string>4be36322f3bf16dfbba67c8df574d446</string>
    1.18                <key>hash_algorithm</key>
    1.19                <string>md5</string>
    1.20                <key>url</key>
    1.21 -              <string>file:///c:/cygwin/opt/firestorm/fmodstudio-1.10.02-windows-173500059.tar.bz2</string>
    1.22 +              <string>file:///c:/cygwin/opt/firestorm/fmodstudio-1.10.03-windows-180491728.tar.bz2</string>
    1.23              </map>
    1.24              <key>name</key>
    1.25              <string>windows</string>
    1.26            </map>
    1.27          </map>
    1.28          <key>version</key>
    1.29 -        <string>1.10.02</string>
    1.30 +        <string>1.10.03</string>
    1.31        </map>
    1.32        <key>fmodex</key>
    1.33        <map>
     2.1 --- a/indra/cmake/Variables.cmake	Tue Feb 27 18:10:09 2018 +0100
     2.2 +++ b/indra/cmake/Variables.cmake	Tue Feb 27 18:13:33 2018 +0100
     2.3 @@ -12,10 +12,7 @@
     2.4  # Switches set here and in 00-Common.cmake must agree with
     2.5  # https://bitbucket.org/lindenlab/viewer-build-variables/src/tip/variables
     2.6  # Reading $LL_BUILD is an attempt to directly use those switches.
     2.7 -# <FS:Ansariel> This causes CMP0054 warning
     2.8 -#if ("$ENV{LL_BUILD}" STREQUAL "")
     2.9 -if ($ENV{LL_BUILD} STREQUAL "")
    2.10 -# </FS:Ansariel>
    2.11 +if ("$ENV{LL_BUILD}" STREQUAL "")
    2.12    message(FATAL_ERROR "Environment variable LL_BUILD must be set")
    2.13  endif ()
    2.14  
     3.1 --- a/indra/llcommon/llcoros.cpp	Tue Feb 27 18:10:09 2018 +0100
     3.2 +++ b/indra/llcommon/llcoros.cpp	Tue Feb 27 18:13:33 2018 +0100
     3.3 @@ -327,11 +327,13 @@
     3.4      // run the code the caller actually wants in the coroutine
     3.5      try
     3.6      {
     3.7 -#if LL_WINDOWS
     3.8 -        winlevel(callable);
     3.9 -#else
    3.10 +// <FS:Ansariel> Disable for more meaningful callstacks
    3.11 +//#if LL_WINDOWS
    3.12 +//        winlevel(callable);
    3.13 +//#else
    3.14 +// </FS:Ansariel>
    3.15          callable();
    3.16 -#endif
    3.17 +//#endif // <FS:Ansariel> Disable for more meaningful callstacks
    3.18      }
    3.19      catch (const LLContinueError&)
    3.20      {
    3.21 @@ -340,12 +342,14 @@
    3.22          // viewer will carry on.
    3.23          LOG_UNHANDLED_EXCEPTION(STRINGIZE("coroutine " << data->mName));
    3.24      }
    3.25 -    catch (...)
    3.26 -    {
    3.27 -        // Any OTHER kind of uncaught exception will cause the viewer to
    3.28 -        // crash, hopefully informatively.
    3.29 -        CRASH_ON_UNHANDLED_EXCEPTION(STRINGIZE("coroutine " << data->mName));
    3.30 -    }
    3.31 +    // <FS:Ansariel> Disable for more meaningful callstacks
    3.32 +    //catch (...)
    3.33 +    //{
    3.34 +    //    // Any OTHER kind of uncaught exception will cause the viewer to
    3.35 +    //    // crash, hopefully informatively.
    3.36 +    //   CRASH_ON_UNHANDLED_EXCEPTION(STRINGIZE("coroutine " << data->mName));
    3.37 +    //}
    3.38 +    // </FS:Ansariel>
    3.39      // This cleanup isn't perfectly symmetrical with the way we initially set
    3.40      // data->mPrev, but this is our last chance to reset Current.
    3.41      Current().reset(data->mPrev);
     4.1 --- a/indra/newview/fsexportperms.cpp	Tue Feb 27 18:10:09 2018 +0100
     4.2 +++ b/indra/newview/fsexportperms.cpp	Tue Feb 27 18:13:33 2018 +0100
     4.3 @@ -55,8 +55,10 @@
     4.4  			F32 max_object_size = LLWorld::getInstance()->getRegionMaxPrimScale();
     4.5  			LLVector3 vec = object->getScale();
     4.6  			if (vec.mV[VX] > max_object_size || vec.mV[VY] > max_object_size || vec.mV[VZ] > max_object_size)
     4.7 +			{
     4.8  				exportable = (creator == LLUUID("7ffd02d0-12f4-48b4-9640-695708fd4ae4") // Zwagoth Klaar
     4.9 -							  || creator == gAgentID);
    4.10 +					|| creator == gAgentID);
    4.11 +			}
    4.12  		}
    4.13  	}
    4.14  #ifdef OPENSIM
    4.15 @@ -82,20 +84,24 @@
    4.16  		}
    4.17  	}
    4.18  #endif // OPENSIM
    4.19 +
    4.20  	// We've got perms on the object itself, let's check for sculptmaps and meshes!
    4.21  	if (exportable)
    4.22  	{
    4.23 -		LLVOVolume *volobjp = NULL;
    4.24 +		exportable = false;
    4.25 +		LLVOVolume* volobjp = NULL;
    4.26 +
    4.27  		if (object->getPCode() == LL_PCODE_VOLUME)
    4.28  		{
    4.29  			volobjp = (LLVOVolume *)object;
    4.30  		}
    4.31 +
    4.32  		if (volobjp && volobjp->isSculpted())
    4.33  		{
    4.34 -			const LLSculptParams *sculpt_params = (const LLSculptParams *)object->getParameterEntry(LLNetworkData::PARAMS_SCULPT);
    4.35 +			const LLSculptParams* sculpt_params = (const LLSculptParams *)object->getParameterEntry(LLNetworkData::PARAMS_SCULPT);
    4.36  			if (LLGridManager::getInstance()->isInSecondLife())
    4.37  			{
    4.38 -				if(volobjp->isMesh())
    4.39 +				if (volobjp->isMesh())
    4.40  				{
    4.41  					if (dae)
    4.42  					{
    4.43 @@ -116,6 +122,7 @@
    4.44  					{
    4.45  						exportable = (LLUUID(imagep->mComment["a"]) == gAgentID);
    4.46  					}
    4.47 +
    4.48  					if (!exportable)
    4.49  					{
    4.50  						LLUUID asset_id = sculpt_params->getSculptTexture();
    4.51 @@ -126,14 +133,17 @@
    4.52  														LLInventoryModel::INCLUDE_TRASH,
    4.53  														asset_id_matches);
    4.54  						
    4.55 -						for (S32 i = 0; i < items.size(); ++i)
    4.56 +						for (S32 i = 0; i < items.size() && !exportable; ++i)
    4.57  						{
    4.58  							const LLPermissions perms = items[i]->getPermissions();
    4.59  							exportable = perms.getCreator() == gAgentID;
    4.60  						}
    4.61  					}
    4.62 +
    4.63  					if (!exportable)
    4.64 +					{
    4.65  						LL_INFOS("export") << "Sculpt map has failed permissions check." << LL_ENDL;
    4.66 +					}
    4.67  				}
    4.68  			}
    4.69  #ifdef OPENSIM
    4.70 @@ -149,7 +159,7 @@
    4.71  													LLInventoryModel::INCLUDE_TRASH,
    4.72  													asset_id_matches);
    4.73  					
    4.74 -					for (S32 i = 0; i < items.size(); ++i)
    4.75 +					for (S32 i = 0; i < items.size() && !exportable; ++i)
    4.76  					{
    4.77  						const LLPermissions perms = items[i]->getPermissions();
    4.78  						switch (LFSimFeatureHandler::instance().exportPolicy())
    4.79 @@ -166,8 +176,11 @@
    4.80  							default:
    4.81  								exportable = perms.getCreator() == gAgentID;
    4.82  						}
    4.83 -						if (!exportable)
    4.84 -							LL_INFOS("export") << "Sculpt map has failed permissions check." << LL_ENDL;
    4.85 +					}
    4.86 +
    4.87 +					if (!exportable)
    4.88 +					{
    4.89 +						LL_INFOS("export") << "Sculpt map has failed permissions check." << LL_ENDL;
    4.90  					}
    4.91  				}
    4.92  				else
    4.93 @@ -179,9 +192,11 @@
    4.94  		}
    4.95  		else
    4.96  		{
    4.97 +			// No sculpt or mesh
    4.98  			exportable = true;
    4.99  		}
   4.100  	}
   4.101 +
   4.102  	return exportable;
   4.103  }
   4.104  
   4.105 @@ -207,39 +222,35 @@
   4.106  		(*name) = items[0]->getName();
   4.107  		(*description) = items[0]->getDescription();
   4.108  		
   4.109 -		for (S32 i = 0; i < items.size(); ++i)
   4.110 +		for (S32 i = 0; i < items.size() && !exportable; ++i)
   4.111  		{
   4.112 -			if (!exportable)
   4.113 +			LLPermissions perms = items[i]->getPermissions();
   4.114 +#ifdef OPENSIM
   4.115 +			if (LLGridManager::getInstance()->isInOpenSim())
   4.116  			{
   4.117 -				LLPermissions perms = items[i]->getPermissions();
   4.118 -#ifdef OPENSIM
   4.119 -				if (LLGridManager::getInstance()->isInOpenSim())
   4.120 +				switch (LFSimFeatureHandler::instance().exportPolicy())
   4.121  				{
   4.122 -					switch (LFSimFeatureHandler::instance().exportPolicy())
   4.123 -					{
   4.124 -						case EXPORT_ALLOWED:
   4.125 -							exportable = (perms.getMaskOwner() & PERM_EXPORT) == PERM_EXPORT;
   4.126 -							break;
   4.127 -						/// TODO: Once enough grids adopt a version supporting exports, get consensus
   4.128 -						/// on whether we should allow full perm exports anymore.
   4.129 -						case EXPORT_UNDEFINED:
   4.130 -							exportable = (perms.getMaskBase() & PERM_ITEM_UNRESTRICTED) == PERM_ITEM_UNRESTRICTED;
   4.131 -							break;
   4.132 -						case EXPORT_DENIED:
   4.133 -						default:
   4.134 -							exportable = perms.getCreator() == gAgentID;
   4.135 -							break;
   4.136 -					}
   4.137 +					case EXPORT_ALLOWED:
   4.138 +						exportable = (perms.getMaskOwner() & PERM_EXPORT) == PERM_EXPORT;
   4.139 +						break;
   4.140 +					/// TODO: Once enough grids adopt a version supporting exports, get consensus
   4.141 +					/// on whether we should allow full perm exports anymore.
   4.142 +					case EXPORT_UNDEFINED:
   4.143 +						exportable = (perms.getMaskBase() & PERM_ITEM_UNRESTRICTED) == PERM_ITEM_UNRESTRICTED;
   4.144 +						break;
   4.145 +					case EXPORT_DENIED:
   4.146 +					default:
   4.147 +						exportable = perms.getCreator() == gAgentID;
   4.148 +						break;
   4.149  				}
   4.150 +			}
   4.151  #endif
   4.152 -				if (LLGridManager::getInstance()->isInSecondLife() && (perms.getCreator() == gAgentID))
   4.153 -				{
   4.154 -					exportable = true;
   4.155 -				}
   4.156 +			if (LLGridManager::getInstance()->isInSecondLife() && (perms.getCreator() == gAgentID))
   4.157 +			{
   4.158 +				exportable = true;
   4.159  			}
   4.160  		}
   4.161  	}
   4.162  	
   4.163  	return exportable;
   4.164  }
   4.165 -
     5.1 --- a/indra/newview/llappearancemgr.cpp	Tue Feb 27 18:10:09 2018 +0100
     5.2 +++ b/indra/newview/llappearancemgr.cpp	Tue Feb 27 18:13:33 2018 +0100
     5.3 @@ -2299,8 +2299,9 @@
     5.4  		//if replacing - make sure bridge stays.
     5.5  		if (!append && FSLSLBridge::instance().getBridge())
     5.6  		{
     5.7 -			LL_INFOS("FSLSLBridge") << "reinserting bridge at outfit replace" << LL_ENDL;
     5.8 +			LL_INFOS("FSLSLBridge") << "Reinserting bridge at outfit replace" << LL_ENDL;
     5.9  			obj_items.insert(obj_items.end(), FSLSLBridge::instance().getBridge());
    5.10 +			LL_INFOS("FSLSLBridge") << "Bridge reinserted" << LL_ENDL;
    5.11  		}
    5.12  	}
    5.13  	// </FS:TT>
     6.1 --- a/indra/newview/llappviewer.cpp	Tue Feb 27 18:10:09 2018 +0100
     6.2 +++ b/indra/newview/llappviewer.cpp	Tue Feb 27 18:13:33 2018 +0100
     6.3 @@ -1438,8 +1438,10 @@
     6.4  	joystick->setNeedsReset(true);
     6.5  	/*----------------------------------------------------------------------*/
     6.6  
     6.7 -	gSavedSettings.getControl("FramePerSecondLimit")->getSignal()->connect(boost::bind(&LLAppViewer::onChangeFrameLimit, this, _2));
     6.8 -	onChangeFrameLimit(gSavedSettings.getLLSD("FramePerSecondLimit"));
     6.9 +	// <FS:Ansariel> FIRE-22297: FPS limiter not working properly on Mac/Linux
    6.10 +	//gSavedSettings.getControl("FramePerSecondLimit")->getSignal()->connect(boost::bind(&LLAppViewer::onChangeFrameLimit, this, _2));
    6.11 +	//onChangeFrameLimit(gSavedSettings.getLLSD("FramePerSecondLimit"));
    6.12 +	// </FS:Ansariel>
    6.13  
    6.14  	return true;
    6.15  }
    6.16 @@ -1580,6 +1582,8 @@
    6.17  	LLTimer periodicRenderingTimer;
    6.18  	BOOL restore_rendering_masks = FALSE;
    6.19  	// </FS:Ansariel> MaxFPS Viewer-Chui merge error
    6.20 +	// <FS:Ansariel> FIRE-22297: FPS limiter not working properly on Mac/Linux
    6.21 +	LLTimer frameTimer;
    6.22  
    6.23  	nd::etw::logFrame(); // <FS:ND> Write the start of each frame. Even if our Provider (Firestorm) would be enabled, this has only light impact. Does nothing on OSX and Linux.
    6.24  
    6.25 @@ -1708,24 +1712,22 @@
    6.26  				pingMainloopTimeout("Main:Display");
    6.27  				gGLActive = TRUE;
    6.28  
    6.29 -				static U64 last_call = 0;
    6.30 -				// <FS:Ansariel> MaxFPS improvement
    6.31 +				// <FS:Ansariel> FIRE-22297: FPS limiter not working properly on Mac/Linux
    6.32 +				//static U64 last_call = 0;
    6.33  				//if (!gTeleportDisplay)
    6.34 -				static LLCachedControl<bool> fsLimitFramerate(gSavedSettings, "FSLimitFramerate");
    6.35 -				if (fsLimitFramerate && !gTeleportDisplay)
    6.36 +				//{
    6.37 +				//	// Frame/draw throttling
    6.38 +				//	U64 elapsed_time = LLTimer::getTotalTime() - last_call;
    6.39 +				//	if (elapsed_time < mMinMicroSecPerFrame)
    6.40 +				//	{
    6.41 +				//		LL_RECORD_BLOCK_TIME(FTM_SLEEP);
    6.42 +				//		// llclamp for when time function gets funky
    6.43 +				//		U64 sleep_time = llclamp(mMinMicroSecPerFrame - elapsed_time, (U64)1, (U64)1e6);
    6.44 +				//		micro_sleep(sleep_time, 0);
    6.45 +				//	}
    6.46 +				//}
    6.47 +				//last_call = LLTimer::getTotalTime();
    6.48  				// </FS:Ansariel>
    6.49 -				{
    6.50 -					// Frame/draw throttling
    6.51 -					U64 elapsed_time = LLTimer::getTotalTime() - last_call;
    6.52 -					if (elapsed_time < mMinMicroSecPerFrame)
    6.53 -					{
    6.54 -						LL_RECORD_BLOCK_TIME(FTM_SLEEP);
    6.55 -						// llclamp for when time function gets funky
    6.56 -						U64 sleep_time = llclamp(mMinMicroSecPerFrame - elapsed_time, (U64)1, (U64)1e6);
    6.57 -						micro_sleep(sleep_time, 0);
    6.58 -					}
    6.59 -				}
    6.60 -				last_call = LLTimer::getTotalTime();
    6.61  
    6.62  				display();
    6.63  
    6.64 @@ -1834,6 +1836,23 @@
    6.65  				}
    6.66  			}
    6.67  
    6.68 +			// <FS:Ansariel> FIRE-22297: FPS limiter not working properly on Mac/Linux
    6.69 +			static LLCachedControl<U32> max_fps(gSavedSettings, "FramePerSecondLimit");
    6.70 +			static LLCachedControl<bool> fsLimitFramerate(gSavedSettings, "FSLimitFramerate");
    6.71 +			if (fsLimitFramerate && LLStartUp::getStartupState() == STATE_STARTED && !gTeleportDisplay && !logoutRequestSent() && max_fps > F_APPROXIMATELY_ZERO)
    6.72 +			{
    6.73 +				// Sleep a while to limit frame rate.
    6.74 +				F32 min_frame_time = 1.f / (F32)max_fps;
    6.75 +				S32 milliseconds_to_sleep = llclamp((S32)((min_frame_time - frameTimer.getElapsedTimeF64()) * 1000.f), 0, 1000);
    6.76 +				if (milliseconds_to_sleep > 0)
    6.77 +				{
    6.78 +					LL_RECORD_BLOCK_TIME(FTM_SLEEP);
    6.79 +					ms_sleep(milliseconds_to_sleep);
    6.80 +				}
    6.81 +			}
    6.82 +			frameTimer.reset();
    6.83 +			// </FS:Ansariel>
    6.84 +
    6.85  			resumeMainloopTimeout();
    6.86  
    6.87  			pingMainloopTimeout("Main:End");
     7.1 --- a/indra/newview/particleeditor.cpp	Tue Feb 27 18:10:09 2018 +0100
     7.2 +++ b/indra/newview/particleeditor.cpp	Tue Feb 27 18:13:33 2018 +0100
     7.3 @@ -622,15 +622,15 @@
     7.4  	}
     7.5  }
     7.6  
     7.7 -void ParticleEditor::scriptInjectReturned( )
     7.8 +void ParticleEditor::scriptInjectReturned()
     7.9  {
    7.10  	setCanClose(TRUE);
    7.11  
    7.12  	// play it safe, because some time may have passed
    7.13  	LLViewerObject* object = gObjectList.findObject(mObject->getID());
    7.14 -	if (!object)
    7.15 +	if (!object || mObject->isDead())
    7.16  	{
    7.17 -		LL_DEBUGS() << "object went away!" << LL_ENDL;
    7.18 +		LL_WARNS() << "Can't inject script - object is dead or went away!" << LL_ENDL;
    7.19  		mMainPanel->setEnabled(TRUE);
    7.20  		return;
    7.21  	}
     8.1 --- a/indra/newview/skins/default/xui/pl/notifications.xml	Tue Feb 27 18:10:09 2018 +0100
     8.2 +++ b/indra/newview/skins/default/xui/pl/notifications.xml	Tue Feb 27 18:13:33 2018 +0100
     8.3 @@ -3425,20 +3425,30 @@
     8.4  Proszę sprawdź swoją sieć i ustawienia firewall.
     8.5  	</notification>
     8.6  	<notification name="NoVoiceConnect">
     8.7 -		Występuje problem z Twoim połączeniem głosowym:
     8.8 +		Nie możemy połączyć się z serwerem głosowym:
     8.9  
    8.10  &lt;nolink&gt;[HOSTID]&lt;/nolink&gt;
    8.11  
    8.12 -Komunikacja głosowa nie będzie dostępna.
    8.13 +Porty, które muszą być otwarte dla połączeń głosowych, to:
    8.14 +:TCP: 80, 443
    8.15 +:UDP: 3478, 3479, 5060, 5062, 6250, 12000-32000
    8.16 +
    8.17  Proszę sprawdź swoją sieć i ustawienia firewall.
    8.18 +Wyłącz wszelkie funkcjonalności SIP ALG (Application Layer Gateway) w swoim routerze.
    8.19 +
    8.20  [http://wiki.phoenixviewer.com/fs_voice Więcej wskazówek można znaleźć tutaj]
    8.21  		<usetemplate name="okignore" ignoretext="Ostrzegaj mnie, gdy przeglądarka nie może połączyć się z serwerem głosu" />
    8.22  	</notification>
    8.23  	<notification name="NoVoiceConnect-GIAB">
    8.24 -		Występuje problem z Twoim połączeniem głosowym.
    8.25 +		Nie możemy połączyć się z serwerem głosowym.
    8.26  
    8.27 -Komunikacja głosowa nie będzie dostępna.
    8.28 +Porty, które muszą być otwarte dla połączeń głosowych, to:
    8.29 +:TCP: 80, 443
    8.30 +:UDP: 3478, 3479, 5060, 5062, 6250, 12000-32000
    8.31 +
    8.32  Proszę sprawdź swoją sieć i ustawienia firewall.
    8.33 +Wyłącz wszelkie funkcjonalności SIP ALG (Application Layer Gateway) w swoim routerze.
    8.34 +
    8.35  [http://wiki.phoenixviewer.com/fs_voice Więcej wskazówek można znaleźć tutaj]
    8.36  	</notification>
    8.37  	<notification name="AvatarRezLeftNotification">

mercurial