diff --git a/calendar/import-export/calMonthGridPrinter.js b/calendar/import-export/calMonthGridPrinter.js index 8daf59cd0c0..83c78b138e5 100644 --- a/calendar/import-export/calMonthGridPrinter.js +++ b/calendar/import-export/calMonthGridPrinter.js @@ -146,7 +146,7 @@ function monthPrint_format(aStream, aStart, aEnd, aCount, aItems, aTitle) { var body = - while (date.month <= end.month) { + while (date.compare(end) <= 0) { var monthName = calGetString("dateFormat", "month." + (date.month +1)+ ".name"); monthName += " " + start.year; body.appendChild(