Use a pair of parentheses to ensure right evaluation order.

This commit is contained in:
delphij 2011-07-11 05:40:46 +00:00
parent d352e8628e
commit 98820bb887

View File

@ -155,7 +155,7 @@ fpom(int year, double utcoffset, double *ffms, double *fnms)
tomorrow = potm(days_tomorrow); /* 31 December 00:00:01 */
olddir = today > tomorrow ? -1 : +1;
yeardays = 1 + isleap(year) ? DAYSPERLEAPYEAR : DAYSPERYEAR; /* reuse */
yeardays = 1 + (isleap(year) ? DAYSPERLEAPYEAR : DAYSPERYEAR); /* reuse */
for (d = 0; d <= yeardays; d++) {
today = potm(days_today);
tomorrow = potm(days_tomorrow);