diff --git a/src/Parser.c b/src/Parser.c index f003b4c..705ea2c 100644 --- a/src/Parser.c +++ b/src/Parser.c @@ -152,7 +152,7 @@ ParseIPv6(char **str, char **out) goto fail; } - while ((c = Iterate(str)) && IsIPv6Char(c)) + while ((c = Iterate(str)) && IsIPv6Char(c) && digits < 8) { char *ipv4; if (isxdigit(c)) diff --git a/src/Routes/RouteUserProfile.c b/src/Routes/RouteUserProfile.c index 4c438b0..a4fc870 100644 --- a/src/Routes/RouteUserProfile.c +++ b/src/Routes/RouteUserProfile.c @@ -185,8 +185,6 @@ ROUTE_IMPL(RouteUserProfile, path, argp) finish: ConfigUnlock(&config); - /* Username is handled by the router, freeing it would cause issues. */ - Free(entry); UserIdFree(userId); UserUnlock(user); JsonFree(request);