Issue #21154:fix gain loss account
Merge pull request #47 from garyhgohoos/21154

Issue #21154:fix gain loss account