obscurestar avatar obscurestar committed 6dfb0fb

10.5 macs will begin looking for mac_legacy rather than mac

Comments (0)

Files changed (4)

indra/viewer_components/updater/llupdatechecker.cpp

 #include "llsd.h"
 #include "llupdatechecker.h"
 #include "lluri.h"
-
+#if LL_DARWIN
+#include <CoreServices/CoreServices.h>
+#endif
 
 #if LL_WINDOWS
 #pragma warning (disable : 4355) // 'this' used in initializer list: yes, intentionally
 public:
 	Implementation(Client & client);
 	~Implementation();
-	void check(std::string const & protocolVersion, std::string const & hostUrl, 
+	void checkVersion(std::string const & protocolVersion, std::string const & hostUrl, 
 			   std::string const & servicePath, std::string channel, std::string version);
 	
 	// Responder:
 }
 
 
-void LLUpdateChecker::check(std::string const & protocolVersion, std::string const & hostUrl, 
+void LLUpdateChecker::checkVersion(std::string const & protocolVersion, std::string const & hostUrl, 
 							std::string const & servicePath, std::string channel, std::string version)
 {
-	mImplementation->check(protocolVersion, hostUrl, servicePath, channel, version);
+	mImplementation->checkVersion(protocolVersion, hostUrl, servicePath, channel, version);
 }
 
 
 }
 
 
-void LLUpdateChecker::Implementation::check(std::string const & protocolVersion, std::string const & hostUrl, 
+void LLUpdateChecker::Implementation::checkVersion(std::string const & protocolVersion, std::string const & hostUrl, 
 											std::string const & servicePath, std::string channel, std::string version)
 {
 	llassert(!mInProgress);
 #ifdef LL_WINDOWS
 	static const char * platform = "win";
 #elif LL_DARWIN
-	static const char * platform = "mac";
+    long versMin;
+    Gestalt(gestaltSystemVersionMinor, &versMin);
+    
+    static const char *platform;
+    if (versMin == 5) //OS 10.5
+    {
+        platform = "mac_legacy";
+    }
+    else 
+    {
+        platform = "mac";
+    }
 #else
 	static const char * platform = "lnx";
 #endif

indra/viewer_components/updater/llupdatechecker.h

 	LLUpdateChecker(Client & client);
 	
 	// Check status of current app on the given host for the channel and version provided.
-	void check(std::string const & protocolVersion, std::string const & hostUrl, 
+	void checkVersion(std::string const & protocolVersion, std::string const & hostUrl, 
 			   std::string const & servicePath, std::string channel, std::string version);
 	
 private:

indra/viewer_components/updater/llupdaterservice.cpp

 		}
 		else
 		{
-			mUpdateChecker.check(mProtocolVersion, mUrl, mPath, mChannel, mVersion);
+			mUpdateChecker.checkVersion(mProtocolVersion, mUrl, mPath, mChannel, mVersion);
 			setState(LLUpdaterService::CHECKING_FOR_UPDATE);
 		}
 	} 

indra/viewer_components/updater/tests/llupdaterservice_test.cpp

-/**
+/** 
  * @file   llupdaterservice_test.cpp
  * @brief  Tests of llupdaterservice.cpp.
  * 
 *****************************************************************************/
 LLUpdateChecker::LLUpdateChecker(LLUpdateChecker::Client & client)
 {}
-void LLUpdateChecker::check(std::string const & protocolVersion, std::string const & hostUrl, 
+void LLUpdateChecker::checkVersion(std::string const & protocolVersion, std::string const & hostUrl, 
 								  std::string const & servicePath, std::string channel, std::string version)
 {}
 LLUpdateDownloader::LLUpdateDownloader(Client & ) {}
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.