summaryrefslogtreecommitdiff
path: root/src/mongo/client/mongo_uri.cpp
diff options
context:
space:
mode:
authorBilly Donahue <billy.donahue@mongodb.com>2020-10-09 20:50:38 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-10-13 19:30:17 +0000
commitff37b70553dbfd0b2aaeabb8a29c4d492507a9d3 (patch)
tree728b9266de70d79901eed31b0e39de0abc78cf24 /src/mongo/client/mongo_uri.cpp
parentbbe604a5b3f94f78a30a76941ea89c0ca5db14d2 (diff)
downloadmongo-ff37b70553dbfd0b2aaeabb8a29c4d492507a9d3.tar.gz
SERVER-50917 util/ctype.h to replace <cctype> & <ctype.h> funcs
Diffstat (limited to 'src/mongo/client/mongo_uri.cpp')
-rw-r--r--src/mongo/client/mongo_uri.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/client/mongo_uri.cpp b/src/mongo/client/mongo_uri.cpp
index ae8322c086c..08454c6b3f7 100644
--- a/src/mongo/client/mongo_uri.cpp
+++ b/src/mongo/client/mongo_uri.cpp
@@ -47,6 +47,7 @@
#include "mongo/db/namespace_string.h"
#include "mongo/stdx/utility.h"
#include "mongo/util/assert_util.h"
+#include "mongo/util/ctype.h"
#include "mongo/util/dns_name.h"
#include "mongo/util/dns_query.h"
#include "mongo/util/hex.h"
@@ -73,7 +74,7 @@ const std::vector<std::pair<std::string, std::string>> permittedTXTOptions = {{"
*/
void mongo::uriEncode(std::ostream& ss, StringData toEncode, StringData passthrough) {
for (const auto& c : toEncode) {
- if ((c == '-') || (c == '_') || (c == '.') || (c == '~') || isalnum(c) ||
+ if ((c == '-') || (c == '_') || (c == '.') || (c == '~') || ctype::isAlnum(c) ||
(passthrough.find(c) != std::string::npos)) {
ss << c;
} else {