summaryrefslogtreecommitdiff
path: root/src/char_sql
diff options
context:
space:
mode:
Diffstat (limited to 'src/char_sql')
-rw-r--r--src/char_sql/int_auction.c4
-rw-r--r--src/char_sql/int_mail.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/char_sql/int_auction.c b/src/char_sql/int_auction.c
index ca99086c7..e29e01e7a 100644
--- a/src/char_sql/int_auction.c
+++ b/src/char_sql/int_auction.c
@@ -79,7 +79,7 @@ unsigned int auction_create(struct auction_data *auction)
if( !auction )
return false;
- auction->timestamp = calc_times() + (auction->hours * 3600);
+ auction->timestamp = time(NULL) + (auction->hours * 3600);
StringBuf_Init(&buf);
StringBuf_Printf(&buf, "INSERT INTO `%s` (`seller_id`,`seller_name`,`buyer_id`,`buyer_name`,`price`,`buynow`,`hours`,`timestamp`,`nameid`,`item_name`,`type`,`refine`,`attribute`", auction_db);
@@ -177,7 +177,7 @@ void inter_auctions_fromsql(void)
struct item *item;
char *data;
StringBuf buf;
- unsigned int tick = gettick(), endtick, now = calc_times();
+ unsigned int tick = gettick(), endtick, now = time(NULL);
StringBuf_Init(&buf);
StringBuf_AppendStr(&buf, "SELECT `auction_id`,`seller_id`,`seller_name`,`buyer_id`,`buyer_name`,"
diff --git a/src/char_sql/int_mail.c b/src/char_sql/int_mail.c
index 963647200..a70b30b99 100644
--- a/src/char_sql/int_mail.c
+++ b/src/char_sql/int_mail.c
@@ -353,7 +353,7 @@ static void mapif_Mail_return(int fd, int char_id, int mail_id)
safestrncpy(msg.title, temp_, MAIL_TITLE_LENGTH);
msg.status = MAIL_NEW;
- msg.timestamp = calc_times();
+ msg.timestamp = time(NULL);
new_mail = mail_savemessage(&msg);
mapif_Mail_new(&msg);
@@ -438,7 +438,7 @@ void mail_sendmail(int send_id, const char* send_name, int dest_id, const char*
if( item != NULL )
memcpy(&msg.item, item, sizeof(struct item));
- msg.timestamp = calc_times();
+ msg.timestamp = time(NULL);
mail_savemessage(&msg);
mapif_Mail_new(&msg);