start working on refactoring mkmonth functions

Ncurses doesn't let me highlight into an intermediate lines buffer.
This commit is contained in:
Kartik K. Agaram 2022-02-15 17:56:12 -08:00
parent f98a8b8f69
commit 0d2e47b598
1 changed files with 2 additions and 2 deletions

4
ncal.c
View File

@ -701,7 +701,7 @@ monthrangeb(int y, int m, int jd_flag, int before, int after, int highlightdate)
while (m <= m2) {
int count = 0;
for (i = 0; i != mpl && m + i <= m2; i++) {
mkmonthb(M2Y(m + i), M2M(m + i) - 1, jd_flag, year + i, highlightdate);
mkmonthb(M2Y(m + i), M2M(m + i) - 1, jd_flag, &year[i], highlightdate);
count++;
}
@ -800,7 +800,7 @@ monthranger(int y, int m, int jd_flag, int before, int after, int highlightdate)
while (m <= m2) {
int count = 0;
for (i = 0; i != mpl && m + i <= m2; i++) {
mkmonthr(M2Y(m + i), M2M(m + i) - 1, jd_flag, year + i, highlightdate);
mkmonthr(M2Y(m + i), M2M(m + i) - 1, jd_flag, &year[i], highlightdate);
count++;
}