mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Fixed Glib-CRITICAL g_date problem for weekly transactions w/o any weekdays selected.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@4908 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
1e36965ded
commit
999211fb3c
@ -775,14 +775,18 @@ mark_calendar( GtkCalendar *cal, FreqSpec *fs )
|
||||
gtk_calendar_select_day( cal, 0 );
|
||||
|
||||
xaccFreqSpecGetNextInstance( fs, gdNow, gdNext );
|
||||
g_date_to_struct_tm( gdNext, tmpTm );
|
||||
if ( g_date_valid( gdNext ) ) {
|
||||
g_date_to_struct_tm( gdNext, tmpTm );
|
||||
} else {
|
||||
tmpTm->tm_mon = -1;
|
||||
}
|
||||
while ( tmpTm->tm_mon == month && g_date_valid(gdNext) ) {
|
||||
gtk_calendar_mark_day( cal, tmpTm->tm_mday );
|
||||
*gdNow = *gdNext;
|
||||
xaccFreqSpecGetNextInstance( fs, gdNow, gdNext );
|
||||
if ( g_date_valid( gdNow ) ) {
|
||||
g_date_to_struct_tm( gdNext, tmpTm );
|
||||
}
|
||||
gtk_calendar_mark_day( cal, tmpTm->tm_mday );
|
||||
*gdNow = *gdNext;
|
||||
xaccFreqSpecGetNextInstance( fs, gdNow, gdNext );
|
||||
if ( g_date_valid( gdNow ) ) {
|
||||
g_date_to_struct_tm( gdNext, tmpTm );
|
||||
}
|
||||
}
|
||||
gtk_calendar_thaw( cal );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user