replace comes from regex

This commit is contained in:
Young Hahn
2014-05-28 18:53:54 -04:00
parent a66db39a06
commit 944167296a

View File

@@ -5,6 +5,7 @@
#include <llmr/util/pbf.hpp>
#include <llmr/platform/platform.hpp>
#include <uv.h>
#include <regex>
namespace llmr {
@@ -27,7 +28,7 @@ GlyphPBF::GlyphPBF(const std::string &fontStack, GlyphRange glyphRange)
std::string url = util::sprintf<255>("http://mapbox.s3.amazonaws.com/gl-glyphs/%s/%d-%d.pbf", fontStack.c_str(), glyphRange.first, glyphRange.second);
// TODO: Find more reliable URL normalization function
// std::replace(url.begin(), url.end(), ' ', '+');
std::replace(url.begin(), url.end(), ' ', '+');
platform::request_http(url, [&](platform::Response *res) {
if (res->code != 200) {