Skip to content

Commit a4a0b75

Browse files
committed
CDRIVER-700 final unchecked errs from mongoc_uri_do_unescape
1 parent 8ca5db7 commit a4a0b75

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/mongoc/mongoc-uri.c

+4
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,10 @@ mongoc_uri_parse_host6 (mongoc_uri_t *uri,
242242
hostname = scan_to_unichar (str + 1, ']', "", &end_host);
243243

244244
mongoc_uri_do_unescape (&hostname);
245+
if (!hostname) {
246+
return false;
247+
}
248+
245249
mongoc_uri_append_host (uri, hostname, port);
246250
bson_free (hostname);
247251

0 commit comments

Comments
 (0)