summaryrefslogtreecommitdiff
path: root/src/UriRecompose.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/UriRecompose.c')
-rw-r--r--src/UriRecompose.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/UriRecompose.c b/src/UriRecompose.c
index 2705cf1..2cdb92d 100644
--- a/src/UriRecompose.c
+++ b/src/UriRecompose.c
@@ -246,7 +246,7 @@ static URI_INLINE int URI_FUNC(ToStringEngine)(URI_CHAR * dest,
}
}
} else {
- (*charsRequired) += charsToWrite + 1;
+ (*charsRequired) += charsToWrite + ((i == 3) ? 0 : 1);
}
}
} else if (uri->hostData.ip6 != NULL) {