anchor.diff:  %%------------------------------------------------------------------------------
   -spec delete_expired_cookies([#lhttpc_cookie{}]) -> [#lhttpc_cookie{}].
   delete_expired_cookies(Cookies) ->
  -    MaxAges = [ X || X <- Cookies, X#lhttpc_cookie.max_age =/= undefined],
  -    ToDelete1 = [ X || X <- MaxAges,
  -		       timer:now_diff(erlang:timestamp(), X#lhttpc_cookie.timestamp)  > X#lhttpc_cookie.max_age],
  -    NewCookies = Cookies -- ToDelete1,
  -    Expires = [ X || X <- Cookies, X#lhttpc_cookie.expires =/= never],
  -    ToDelete2 = [ X || X <- Expires,
  -		       calendar:datetime_to_gregorian_seconds(calendar:universal_time())  >
  -			   calendar:datetime_to_gregorian_seconds(X#lhttpc_cookie.expires)],
  +    ToDelete = [ X || X <- Cookies,
  +		      X#lhttpc_cookie.max_age =/= undefined andalso
  +			  timer:now_diff(erlang:timestamp(), X#lhttpc_cookie.timestamp)  > X#lhttpc_cookie.max_age],
  +    NewCookies = Cookies -- ToDelete,
  +    ToDelete2 =  [ X || X <- Cookies, X#lhttpc_cookie.expires =/= never andalso
  +			    calendar:datetime_to_gregorian_seconds(calendar:universal_time())  >
  +			    calendar:datetime_to_gregorian_seconds(X#lhttpc_cookie.expires)],
       NewCookies -- ToDelete2.
   
   %%------------------------------------------------------------------------------
  
positive.code:     ReceivedCookies = lhttpc_lib:get_cookies(RespHeaders),
      %substitute the cookies with the same name, add the others.
      Names = [ X#lhttpc_cookie.name || X <- ReceivedCookies],
      A = fun(List) ->
  		fun(X) ->
  			length(List) =:=
  			    length(lists:usort(List -- [X#lhttpc_cookie.name])) end
  	end,
      OldCookies = lists:filter(A(Names), StateCookies),
      FinalCookies = ReceivedCookies ++ OldCookies,
      %delete the cookies whose value is set to "deleted"
      DeleteCookies = [ X#lhttpc_cookie.name || X <- ReceivedCookies, X#lhttpc_cookie.value =:= "deleted"],
  
negative.code: 				 {{integer(), integer(), integer()},
  				  {integer(),integer(),integer()}}.
  expires_to_datetime(ExpireDate) ->
      [_Expires, Day, Month, Year, Hour, Min, Sec, _GMT] = string:tokens(ExpireDate, ", -:"),
      {FinalDay, _} = string:to_integer(Day),
      {FinalYear, _} = string:to_integer(Year),
      {FinalHour, _} = string:to_integer(Hour),
      {FinalMin, _} =string:to_integer(Min),
      {FinalSec, _} =string:to_integer(Sec),
      FinalMonth = month_to_integer(Month),
      {{FinalYear, FinalMonth, FinalDay}, {FinalHour, FinalMin, FinalSec}}.
  
  
  %%------------------------------------------------------------------------------
  