Control: tags -1 patch

On Tue, Sep 02, 2025 at 11:37:39PM +0200, Alberto Garcia wrote:

> homebank 5.8.6-1 (trixie) segfaults when I try to open the details
> of some transactions. The version in sid (currently 5.9.1-1) is not
> affected.

I had a closer look at this, here is the upstream bug:

   https://bugs.launchpad.net/homebank/+bug/2109861

And the attached patch seems enough to fix it.

Berto
diff --git a/src/ui-transaction.c b/src/ui-transaction.c
index 96950f1..4127531 100644
--- a/src/ui-transaction.c
+++ b/src/ui-transaction.c
@@ -940,7 +940,9 @@ Account *acc;
 		}
 		
 		//#1867979 todate
-		gtk_date_entry_set_date(GTK_DATE_ENTRY(data->PO_dateto), (guint)child->date);
+		//#2109861 child can be null
+		if( PREFS->xfer_syncdate == FALSE && child != NULL )
+			gtk_date_entry_set_date(GTK_DATE_ENTRY(data->PO_dateto), (guint)child->date);
 		
 	}
 
@@ -1002,10 +1004,14 @@ Account *acc;
 			}
 			else	// just sync the existing xfer
 			{
-				//#1584342 was faultly old_txn
-				transaction_xfer_child_sync(new_txn, child);
-				//#1867979 todate
-				child->date = gtk_date_entry_get_date(GTK_DATE_ENTRY(data->PO_dateto));
+				//#2109861 child can be null
+				if( child != NULL)
+				{
+					//#1584342 was faultly old_txn
+					transaction_xfer_child_sync(new_txn, child);
+					//#1867979 todate
+					child->date = gtk_date_entry_get_date(GTK_DATE_ENTRY(data->PO_dateto));
+				}
 				accchanged = TRUE;
 			}
 		}

Reply via email to