File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -199,8 +199,17 @@ namespace Url
199
199
}
200
200
}
201
201
202
+ // Windows local file path
203
+ if (static_cast <int >(url.length () - position) >= 4
204
+ && url[position] == ' /'
205
+ && url[position + 1 ] == ' /'
206
+ && url[position + 2 ] == ' /'
207
+ && url[position + 4 ] == ' :' )
208
+ {
209
+ position += 3 ;
210
+ }
202
211
// Search for the netloc
203
- if ((url.length () - position) >= 1
212
+ else if ((url.length () - position) >= 1
204
213
&& url[position] == ' /'
205
214
&& url[position + 1 ] == ' /' )
206
215
{
@@ -443,7 +452,8 @@ namespace Url
443
452
}
444
453
else
445
454
{
446
- if (!host_.empty () && path_[0 ] != ' /' )
455
+ if ((!host_.empty () && path_[0 ] != ' /' ) ||
456
+ (host_.empty () && path_[0 ] != ' /' && path_[2 ] == ' :' ))
447
457
{
448
458
result.append (1 , ' /' );
449
459
}
You can’t perform that action at this time.
0 commit comments