Fix timestamps for data files and lost command

Set the ef_timestamp to 100 for the nightly build.
Set the DUMP LOST timestamp to 101 for the nightly build.
This will the suppress the timestamp differences
that occur when testing lost command and will facilitate
testing for dump and xdump commands.
This commit is contained in:
Ron Koenderink 2008-08-17 15:13:57 -06:00
parent 8c404f5b7f
commit 851ccd4876
2 changed files with 26 additions and 0 deletions

View file

@ -0,0 +1,13 @@
diff --git a/src/lib/common/file.c b/src/lib/common/file.c
index ae851ae..872c363 100644
--- a/src/lib/common/file.c
+++ b/src/lib/common/file.c
@@ -384,7 +384,7 @@ do_write(struct empfile *ep, void *buf, int id, int count)
return -1;
if (ep->flags & EFF_TYPED) {
- now = ep->flags & EFF_NOTIME ? (time_t)-1 : time(NULL);
+ now = ep->flags & EFF_NOTIME ? (time_t)-1 : (time_t)100;
for (i = 0; i < count; i++) {
/*
* TODO Oopses here could be due to bad data corruption.

View file

@ -0,0 +1,13 @@
diff --git a/src/lib/commands/lost.c b/src/lib/commands/lost.c
index 8e410e6..b29c0a2 100644
--- a/src/lib/commands/lost.c
+++ b/src/lib/commands/lost.c
@@ -51,7 +51,7 @@ lost(void)
prdate();
nlost = 0;
- time(&now);
+ now = (time_t)101;
pr("DUMP LOST ITEMS %ld\n", (long)now);
if (player->god)
pr("owner ");