misc stuff

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@792 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Linas Vepstas 1998-04-07 05:31:27 +00:00
parent 1671e86c72
commit 8e195768a5
4 changed files with 13 additions and 2 deletions

View File

@ -760,6 +760,12 @@ xaccAccountGetBalance (Account *acc)
return (acc->balance);
}
double
xaccAccountGetClearedBalance (Account *acc)
{
return (acc->cleared_balance);
}
double
xaccAccountGetReconciledBalance (Account *acc)
{

View File

@ -110,6 +110,7 @@ AccountGroup * xaccAccountGetChildren (Account *);
AccountGroup * xaccAccountGetParent (Account *);
double xaccAccountGetBalance (Account *);
double xaccAccountGetClearedBalance (Account *);
double xaccAccountGetReconciledBalance (Account *);
Split * xaccAccountGetSplit (Account *acc, int i);
Split ** xaccAccountGetSplitList (Account *acc);

View File

@ -328,7 +328,7 @@ readGroup (int fd, Account *aparent, int token)
\********************************************************************/
static Account *
readAccount( int fd, AccountGroup *grp, int token )
{
{
int err=0;
int i;
int numTrans, accID;
@ -401,6 +401,7 @@ readAccount( int fd, AccountGroup *grp, int token )
}
xaccAccountRecomputeBalance (acc);
return acc;
}
@ -719,7 +720,7 @@ readTransaction( int fd, Account *acc, int token )
}
}
}
return trans;
}

View File

@ -106,6 +106,7 @@ xaccFreeSplit( Split *split )
split->damount = 0.0;
split->share_price = 1.0;
split->parent = NULL;
split->acc = NULL;
_free(split);
}
@ -149,6 +150,8 @@ xaccSplitDestroy (Split *split)
numsplits = 0;
s = trans->splits[0];
while (s) {
/* xxxxxxx */
printf ("trans %p, %d %p\n", trans, numsplits, s);
MARK_SPLIT(s);
if (s == split) ismember = 1;
numsplits ++;