Commit 78b335b8 authored by Thomas Jahns's avatar Thomas Jahns 🤸
Browse files

Add prototypes for calendar functions.

* And make functions not called outside the file static.
parent c3170d48
......@@ -2,6 +2,7 @@
#include <stdio.h>
#include "cdi.h" /* CALENDAR_ */
#include "calendar.h"
#include "error.h"
#include "timebase.h"
......@@ -128,7 +129,7 @@ static int encode_day(int dpy, int year, int month, int day)
}
int date_to_calday(int calendar, int date)
static int date_to_calday(int calendar, int date)
{
int calday;
int dpy;
......@@ -147,7 +148,7 @@ int date_to_calday(int calendar, int date)
}
int calday_to_date(int calendar, int calday)
static int calday_to_date(int calendar, int calday)
{
int date;
int dpy;
......
......@@ -6,6 +6,11 @@ void encode_caldaysec(int calendar, int year, int month, int day, int hour, int
void decode_caldaysec(int calendar, int julday, int secofday,
int *year, int *month, int *day, int *hour, int *minute, int *second);
int calendar_dpy(int calendar);
int days_per_year(int calendar, int year);
int days_per_month(int calendar, int year, int month);
#endif /* _CALENDAR_H */
/*
* Local Variables:
......
......@@ -5,14 +5,13 @@
#include <stddef.h>
#include <string.h>
#include "dmemory.h"
#include "cdi.h"
#include "calendar.h"
#include "dmemory.h"
#include "error.h"
#include "taxis.h"
#include "cdi_cksum.h"
#include "cdi_int.h"
#include "calendar.h"
#include "namespace.h"
#include "serialize.h"
#include "resource_handle.h"
......@@ -1013,8 +1012,6 @@ void cdiEncodeTimevalue(int days, int secs, int timeunit, double *timevalue)
}
}
int days_per_month(int calendar, int year, int month);
void timeval2vtime(double timevalue, taxis_t *taxis, int *vdate, int *vtime)
{
int year, month, day, hour, minute, second;
......
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