summaryrefslogtreecommitdiff
path: root/platform/darwin/src/http_file_source.mm
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2017-02-03 15:59:42 -0800
committerJohn Firebaugh <john.firebaugh@gmail.com>2017-02-08 10:59:59 -0600
commit150b938b4922ec162bcb593c365e3d3616e0dbd7 (patch)
treeedc3cf391f8971e98752fe1c52f8513afeb71cef /platform/darwin/src/http_file_source.mm
parentd3ca6c67f1b8fbf5d71c307e71ba89a483ec75bc (diff)
downloadqtlocation-mapboxgl-150b938b4922ec162bcb593c365e3d3616e0dbd7.tar.gz
[build, ios, macos] Simplify version portion of user agent string
The X.Y.Z version portion was unreliable, as it pulled from the latest tag regardless of platform. Set version to 0.0.0 and retrieve only the hash, which allows us to drop the node/npm dependency.
Diffstat (limited to 'platform/darwin/src/http_file_source.mm')
-rw-r--r--platform/darwin/src/http_file_source.mm5
1 files changed, 2 insertions, 3 deletions
diff --git a/platform/darwin/src/http_file_source.mm b/platform/darwin/src/http_file_source.mm
index f4b2f8af01..649cebb47f 100644
--- a/platform/darwin/src/http_file_source.mm
+++ b/platform/darwin/src/http_file_source.mm
@@ -4,7 +4,6 @@
#include <mbgl/util/http_header.hpp>
#include <mbgl/util/async_task.hpp>
-
#include <mbgl/util/version.hpp>
#import <Foundation/Foundation.h>
@@ -133,8 +132,8 @@ NSString *HTTPFileSource::Impl::getUserAgent() const {
// Avoid %s here because it inserts hidden bidirectional markers on macOS when the system
// language is set to a right-to-left language.
- [userAgentComponents addObject:[NSString stringWithFormat:@"MapboxGL/%@ (%@)",
- CFSTR(MBGL_VERSION_STRING), CFSTR(MBGL_VERSION_REV)]];
+ [userAgentComponents addObject:[NSString stringWithFormat:@"MapboxGL/0.0.0 (%@)",
+ @(mbgl::version::revision)]];
NSString *systemName = @"Darwin";
#if TARGET_OS_IPHONE