]> git.ipfire.org Git - thirdparty/curl.git/commit
cookies: track expiration in jar to optimize removals
authorDaniel Gustafsson <daniel@yesql.se>
Tue, 8 Jun 2021 07:16:58 +0000 (09:16 +0200)
committerDaniel Gustafsson <daniel@yesql.se>
Tue, 8 Jun 2021 07:31:19 +0000 (09:31 +0200)
commit1bd4b3f4e20d366b7e7dcefefbc5cf4ede341e1e
treeb112fcbbbe9aa2ec85778f835fc7a8f4b7cc57cc
parent3d01b75077708142a66d4f50337c8d8534cce0f4
cookies: track expiration in jar to optimize removals

Removing expired cookies needs to be a fast operation since we want to
be able to perform it often and speculatively. By tracking the timestamp
of the next known expiration we can exit early in case the timestamp is
in the future.

Closes: #7172
Reviewed-by: Daniel Stenberg <daniel@haxx.se>
lib/cookie.c
lib/cookie.h