Commit e2509562 authored by thomas.forbriger's avatar thomas.forbriger Committed by thomas.forbriger
Browse files

updated time reading routines in libtime

This is a legacy commit from before 2015-03-01.
It may be incomplete as well as inconsistent.
See COPYING.legacy and README.history for details.
include correct sub-path in refract Makefile


SVN Path:     http://gpitrsvn.gpi.uni-karlsruhe.de/repos/TFSoftware/trunk
SVN Revision: 216
SVN UUID:     67feda4a-a26e-11df-9d6e-31afc202ad0c
parent 81d1161d
......@@ -3,10 +3,12 @@
*
* 12/08/97 by Thomas Forbriger (IfG Stuttgart)
*
* PURPOSE
* C interface to FORTRAN libtime
*
* REVISIONS and CHANGES
* 12/08/97 V1.0 Thomas Forbriger
* 01/08/00 V1.1 if month is not zero call time_fullyear in time_read
* before time_setdoy
*
* ============================================================================
*/
......@@ -334,6 +336,7 @@ char *String;
Date->micsec=milmicsec-(Date->milsec*1000);
}
if (month>0) { time_fullyear(&Date->year); }
time_setdoy(day, month, Date);
time_finish(Date);
......
......@@ -13,6 +13,8 @@ c changed time_compare looking for date(1) instead
c of date(0)
c 13/08/97 V1.02 time_clear still did clear up to element 8
c 02/02/99 V1.03 added time_read
c 01/08/00 V1.04 in time_read: if month value OR year value is greater
c than zero expect absolute time
c
c----------------------------------------------------------------------
c
......@@ -75,7 +77,7 @@ c returns the actual library version
c
cE
real version
parameter(version=1.03)
parameter(version=1.04)
time_libversion=version
return
end
......@@ -632,9 +634,10 @@ c read seconds
first=last+1
endif
c
if (numbers(1).gt.0) then
if ((numbers(1).gt.0).or.(numbers(2).gt.0)) then
c absolute date
date(1)=numbers(1)
call time_fullyear(date(1))
call time_setdoy(numbers(3),numbers(2),date)
else
c relative date
......
#
# $Id: Makefile,v 2.3 2000-07-29 15:29:05 thof Exp $
# $Id: Makefile,v 2.4 2000-08-01 11:47:34 thof Exp $
#
# Makefile for prog/plot/refract
#
......@@ -57,7 +57,7 @@ refract: $(REFOBS)
docs: $(DOCS)
make.incdep: *.f subs/*.f
make.incdep: *.f sub/*.f
incdep > make.incdep
flist: *.f sub/*.f include/*.inc Makefile
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment