From 9c957c4a0964ee1f5b0ff582543b9f526978c47e Mon Sep 17 00:00:00 2001 From: Jeffrey Armstrong Date: Wed, 6 May 2020 16:43:50 -0400 Subject: Fixed URL handling when base url doesn't end in a slash --- protocol.f90 | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/protocol.f90 b/protocol.f90 index 087e96a..76fb8d4 100644 --- a/protocol.f90 +++ b/protocol.f90 @@ -143,7 +143,11 @@ contains if(path(1:1) == "/") then first_slash = index(current_url(past_protocol:len_trim(current_url)), "/") - current_url = current_url(1:(past_protocol + first_slash - 1))//path(2:len_trim(path)) + if(first_slash < 1) then + current_url = trim(current_url)//trim(path) + else + current_url = current_url(1:(past_protocol + first_slash - 1))//path(2:len_trim(path)) + end if else -- cgit v1.2.3