John Ralls
1e289cb2b8
GncDate: Remove pointless normalize_month function.
...
Suggested by Sherlock.
2023-12-08 13:47:24 -08:00
John Ralls
966cef19aa
Bug 799156 - normalize_struct_tm() does not normalize seconds,...
...
minutes, and hours correctly.
Fix proposed by Sherlock.
2023-12-08 13:45:04 -08:00
John Ralls
5005c3cac8
Merge Sherlock's 'bug799151' into stable.
2023-12-07 17:31:33 -08:00
Sherlock
ae8492d73a
Update test-gnc-date.c
2023-12-07 17:31:19 -08:00
Sherlock
5a7b6e9814
Bug 799151 - gnc_date_get_last_mday () does not account for,,,
...
leap years correctly.
2023-12-07 17:30:08 -08:00
Sherlock
07e94b4222
Bug 799152 - normalize_reldate_tm() does not handle dates with...
...
months greater than 11 or less than -11 correctly.
2023-12-07 16:53:05 -08:00
John Ralls
d8dacb86b2
Bug 799143 - FTBFS on 32bit architectures
...
Fix misuse of GUINT_TO_POINTER in 5e09b66 .
2023-11-28 01:47:12 +00:00
John Ralls
92de074e49
Bug 799144 - Date Completion is broken after 5.4 upgrade
...
strptime will reasonable return false for an incomplete date but it
still fills in the parts of the struct tm that it understands, so bail
out of qof_scan_date_internal when it fails only if all three fields
are present.
2023-11-26 09:23:58 -08:00
John Ralls
ed4921271c
Bug 799134 - Fails to build with GCC 14 (‘find_if’ is not a member...
...
of ‘std’; did you mean ‘find’)
2023-11-21 15:27:04 -08:00
Christopher Lam
1d26d99ddb
[gnc-budget] use std::optional<gnc_numeric> instead of bool+gnc_numeric
...
more expressive
2023-11-18 08:59:32 +08:00
Christopher Lam
fdcb8b46bd
[sixtp-dom-generators.cpp] char* must be freed
2023-11-11 12:45:57 +08:00
Christopher Lam
8f7eecd3e9
Merge branch 'icu-list-formatter' into stable #1791
2023-11-10 18:58:35 +08:00
Christopher Lam
9e47c297ba
Merge branch 'plug-recurrence-to-string' into stable #1812
2023-11-07 06:28:39 +08:00
Christopher Lam
12f4233396
recurrencePeriodTypeToString and recurrenceWeekendAdjustToString g_strdup only when necessary
...
... for sql use only. xml use assumes they return a const char*.
2023-11-06 17:37:17 +08:00
Adam Wight
fbc183a544
Always return an allocated gchar*
...
Returning the literal string will cause the caller to free unallocated
memory.
2023-11-05 23:58:01 +01:00
Christopher Lam
d617129db8
avoid strlen where possible
...
if testing emptiness, test *str instead.
2023-11-01 22:43:16 +08:00
Simon Arlott
90c9aaf4cb
Bug 799108 - "Since Last Run" crashes if there are any errors creating a scheduled transaction
...
Pass a creation_errors list to gnc_sx_instance_model_effect_change() so
that errors creating SX can be stored, and then display them.
2023-10-21 20:39:23 +01:00
John Ralls
4592530318
Bug 799099 - Crash when trying to get quotes
...
The comment on gnc_pricedb_add_price says that writing to the
GNCPrice* after calling it will produce interesting results, and
calling gnc_price_commit_edit and g_object_unref both qualify, so
remove those calls and the corresponding gnc_price_begin_edit.
2023-10-20 08:46:57 -07:00
Sherlock
52f1076b30
Bug 799104 - "Asset Chart" broken
2023-10-13 16:58:54 -07:00
John Ralls
44c278a82c
Fix GncDateEntry date parsing oddities.
...
The intent was always to default to today if the input string isn't
parsable, but two problems prevented that: First,
qof_scan_date_internal didn't check the return value of strptime and
return FALSE if it failed and second gnc_date_edit_get_date_internal
would unnecessarily munge a valid struct tm from gnc_tm_get_today_neutral.
2023-10-12 15:51:35 -07:00
John Ralls
a389e0a32e
Bug 799092 - GnuCash 5.4 leaves background process running on exit
...
Clear the schema_hash at app shutdown via gnc_prefs_remove_registered
and make that function available to the Python bindings so that
python programs can do so too.
2023-10-02 12:31:59 -07:00
Christopher Lam
ab7ead39ca
use icu::ListFormatter to combine a list strings into a string
2023-10-02 17:52:54 +08:00
Christopher Lam
d1b2368f4d
Merge Yongun Seong's branch 'utest-gnc-pricedb-types' into stable #1784
2023-09-27 22:16:39 +08:00
Yongun Seong
0bd556c581
[utest-gnc-pricedb] fix test failure due to callback type mismatch
2023-09-25 15:38:06 +09:00
John Ralls
422fd0cab2
Fix misspelled/missing dist files.
2023-09-23 14:01:11 -07:00
John Ralls
776a430734
Bug 798904 - GnuCash on Windows opens a CMD window at startup.
...
Applied patch from bug report supplied by "Sherlock".
2023-09-22 13:21:11 -07:00
John Ralls
90b9142096
[DBI backend] Change DBI test URLs to environment variables.
...
From cmake configuration definitions.
2023-09-21 14:33:50 -07:00
Christopher Lam
550c43d13a
Merge branch 'free-guid-string' into stable #1777
2023-09-20 07:29:16 +08:00
John Ralls
a49fd0bc09
[c++options] Correctly implement handling Fancy Date Format.
...
It's not a simple string.
2023-09-19 16:05:53 -07:00
Christopher Lam
8e21d3328f
guid_to_string should be freed.
2023-09-19 20:31:11 +08:00
Christopher Lam
d21698f7cf
[gnc-option-impl] don't leak char*
...
use the stack
2023-09-19 07:59:53 +08:00
Christopher Lam
55b9382ad9
[utest-gnc-backend-sql] properly clean up QofBook
2023-09-19 07:59:38 +08:00
Christopher Lam
01f27e9c53
[test-commodities] clean up commodities
2023-09-19 07:59:38 +08:00
Christopher Lam
fccf0b48c4
[utest-Account] g_free char*
2023-09-19 07:59:38 +08:00
Christopher Lam
c074b82224
[test-qofsession] plugs Account* leak
2023-09-17 08:37:09 +08:00
Christopher Lam
1ddee7dc3f
[test-qofbook] plugs Account* leak
2023-09-17 08:37:04 +08:00
Christopher Lam
a81bc72fb1
[test-sx] plug some leaks
2023-09-16 08:42:42 +08:00
Christopher Lam
94211c2e57
[test-sx] plug some leaks
2023-09-16 08:42:40 +08:00
Christopher Lam
14622e7db6
[test-print-parse-amount] plug leaks
2023-09-16 05:46:46 +08:00
Christopher Lam
c44194606a
[test-xml-pricedb] free a sixtp parser
2023-09-15 23:55:06 +08:00
Christopher Lam
34564ef6d0
[test-qofobject] plug some leaks
2023-09-15 23:34:43 +08:00
Christopher Lam
8277f4d559
[test-qofbook] plug leaks
2023-09-15 23:34:43 +08:00
Christopher Lam
0056e5f091
[gtest-import-map] plug leaks
2023-09-15 23:34:43 +08:00
Christopher Lam
235e24a055
[account.cpp] ~GncImapInfo = gnc_account_imap_info_destroy
2023-09-15 23:34:43 +08:00
Christopher Lam
db77fb81a5
[test-job] plug leaks
2023-09-15 23:34:43 +08:00
Christopher Lam
a8dffb8559
[gnc-date.cpp] don't alloc tm* unless GncDateTime() succeeds
...
because GncDateTime() may throw an exception, in which case time will
leak. mainly leaks in test suite.
2023-09-15 23:33:47 +08:00
Christopher Lam
5a03d9798c
[gnc-sx-instance-model] g_free char*
2023-09-15 23:33:47 +08:00
John Ralls
16c9957cac
Bug 798925 - Python bindings: "invalid unclassed pointer...
...
in cast to 'QofInstance'".
The list ended up with two entries of payment_lot resulting in a
dangling reference when one of them was freed.
2023-09-11 17:40:48 -07:00
John Ralls
89360252fb
Bug 798983 - Empty Orphan account appears after entering transactions in 5.3
...
Caused by trying to set the account on the blank split. The blank split
was present because the method used to clear the split list for the
receiving transaction in gnc_float_txn_to_txn_swap_accounts only removed
splits that belong to the transaction, and the blank split doesn't.
Adds new function xaccTransClearSplits to do a more thorough job.
Also improve the documentation for xaccSplitDestroy to better explain when
a transaction will be destroyed if it empties the split list.
# Please enter the commit message for your
changes. Lines starting
2023-09-08 15:08:44 -07:00
Christopher Lam
7ce4198c20
rename string_to_gnc_numeric to gnc_numeric_from_string
2023-08-29 08:45:20 +08:00