1 .\" Copyright 2001 Walter Harms (walter.harms@informatik.uni-oldenburg.de)
3 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
5 .\" aeb: some corrections
6 .TH DYSIZE 3 2021-03-22 "Linux man-pages (unreleased)"
8 dysize \- get number of days for a given year
11 .RI ( libc ", " \-lc )
14 .B "#include <time.h>"
16 .BI "int dysize(int " year );
20 Feature Test Macro Requirements for glibc (see
21 .BR feature_test_macros (7)):
28 Glibc 2.19 and earlier:
29 _BSD_SOURCE || _SVID_SOURCE
32 The function returns 365 for a normal year and 366 for a leap year.
33 The calculation for leap year is based on:
37 (year) %4 == 0 && ((year) %100 != 0 || (year) %400 == 0)
41 The formula is defined in the macro
46 For an explanation of the terms used in this section, see
54 Interface Attribute Value
57 T} Thread safety MT-Safe
63 This function occurs in SunOS 4.x.
65 This is a compatibility function only.
66 Don't use it in new programs.
67 .\" The SCO version of this function had a year-2000 problem.