wininet(3/6): Default to 10 minutes expiration for cache entries

Dmitry Timoshkov dmitry at codeweavers.com
Thu Mar 3 02:05:05 CST 2011


Juan Lang <juan.lang at gmail.com> wrote:

> +    if (!expirationFound)
> +    {
> +        SYSTEMTIME st;
> +
> +        /* With no known age, default to 10 minutes until expiration. */
> +        GetSystemTime(&st);
> +        if (st.wMinute < 50)
> +            st.wMinute += 10;
> +        else
> +        {
> +            st.wHour += 1;
> +            st.wMinute -= 50;
> +        }
> +        SystemTimeToFileTime(&st, &request->expires);
>      }

Well, st.wHour could also everflow, it shuild be easier to add an appropriate
period to the resulting 64-bit number.

-- 
Dmitry.



More information about the wine-devel mailing list