summaryrefslogtreecommitdiff
path: root/src/net/eathena
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-09-05 03:25:42 +0300
committerAndrei Karas <akaras@inbox.ru>2017-09-05 03:25:42 +0300
commit21159adfd8bd3d709793006e1b1e4b2d8ed806d7 (patch)
tree29f13a5be8a9256eec409bbe6ab89bc03c9de4c6 /src/net/eathena
parent0491808a50932918ce09c98a394a941b9239670a (diff)
downloadplus-21159adfd8bd3d709793006e1b1e4b2d8ed806d7.tar.gz
plus-21159adfd8bd3d709793006e1b1e4b2d8ed806d7.tar.bz2
plus-21159adfd8bd3d709793006e1b1e4b2d8ed806d7.tar.xz
plus-21159adfd8bd3d709793006e1b1e4b2d8ed806d7.zip
Fix send date in mails.
Diffstat (limited to 'src/net/eathena')
-rw-r--r--src/net/eathena/mail2recv.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/net/eathena/mail2recv.cpp b/src/net/eathena/mail2recv.cpp
index 8b4d1dd8b..536425386 100644
--- a/src/net/eathena/mail2recv.cpp
+++ b/src/net/eathena/mail2recv.cpp
@@ -48,6 +48,7 @@
#include "utils/checkutils.h"
#include "utils/gettext.h"
#include "utils/stringutils.h"
+#include "utils/timer.h"
#include "debug.h"
@@ -345,7 +346,7 @@ void Mail2Recv::processMailListPage(Net::MessageIn &msg)
mail->type = static_cast<MailMessageType::Type>(
msg.readUInt8("type"));
mail->sender = msg.readString(24, "sender name");
- mail->time = msg.readInt32("reg time");
+ mail->time = cur_time - msg.readInt32("reg time");
mail->strTime = timeToStr(mail->time);
mail->expireTime = msg.readInt32("expire time");
mail->title = msg.readString(-1, "title");