code tidy-up

This commit is contained in:
Aleksandar Fabijanic
2013-06-17 21:56:53 -05:00
parent d5ec46b9fc
commit 0c50f6241c
3 changed files with 58 additions and 29 deletions

View File

@@ -115,7 +115,7 @@ HTTPCookie::HTTPCookie(const NameValueCollection& nvc):
int tzd;
DateTime exp = DateTimeParser::parse(value, tzd);
Timestamp now;
setMaxAge((int) ((exp.timestamp() - now)/Timestamp::resolution()));
setMaxAge((int) ((exp.timestamp() - now) / Timestamp::resolution()));
}
else if (icompare(name, "version") == 0)
{
@@ -259,7 +259,7 @@ std::string HTTPCookie::toString() const
if (_maxAge != -1)
{
Timestamp ts;
ts += _maxAge*Timestamp::resolution();
ts += _maxAge * Timestamp::resolution();
result.append("; expires=");
DateTimeFormatter::append(result, ts, DateTimeFormat::HTTP_FORMAT);
}