From 002f976cdc890589ae4ab7e99519f52421ca6837 Mon Sep 17 00:00:00 2001 From: Daniel Gustafsson Date: Thu, 3 Jun 2021 13:02:09 +0200 Subject: [PATCH] cookies: fix typo and expand comment Fix a typo in the sorting comment, and while in there elaborate slightly on why creationtime can be used as a tiebreaker. --- lib/cookie.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/cookie.c b/lib/cookie.c index fde6a84ce..537658fc6 100644 --- a/lib/cookie.c +++ b/lib/cookie.c @@ -1221,7 +1221,8 @@ fail: * * Helper function to sort cookies such that the longest path gets before the * shorter path. Path, domain and name lengths are considered in that order, - * with tge creationtime as the tiebreaker. + * with the creationtime as the tiebreaker. The creationtime is guaranteed to + * be unique per cookie, so we know we will get an ordering at that point. */ static int cookie_sort(const void *p1, const void *p2) {