1 #if !defined(lint) && !defined(DOS)
2 static char rcsid
[] = "$Id: adjtime.c 761 2007-10-23 22:35:18Z hubert@u.washington.edu $";
6 * ========================================================================
7 * Copyright 2006 University of Washington
9 * Licensed under the Apache License, Version 2.0 (the "License");
10 * you may not use this file except in compliance with the License.
11 * You may obtain a copy of the License at
13 * http://www.apache.org/licenses/LICENSE-2.0
15 * ========================================================================
18 #include "../pith/headers.h"
19 #include "../pith/adjtime.h"
23 * MSC ver 7.0 and less times are since 1900, everybody else's time so far
24 * is since 1970. sheesh.
26 #if defined(DOS) && (_MSC_VER == 700)
27 #define EPOCH_ADJ ((time_t)((time_t)(70*365 + 18) * (time_t)86400))
31 * Adjust the mtime to return time since Unix epoch. DOS is off by 70 years.
38 tt
= time((time_t *)0);
49 get_adj_name_file_mtime(char *name
)
53 mtime
= name_file_mtime(name
);
56 if(mtime
!= (time_t)(-1))