gnucash master: Restore price source_name list compatibility with PriceSource enum.
John Ralls
jralls at code.gnucash.org
Thu Dec 3 16:21:00 EST 2015
Updated via https://github.com/Gnucash/gnucash/commit/9d4bc7f0 (commit)
from https://github.com/Gnucash/gnucash/commit/90601ac4 (commit)
commit 9d4bc7f05aaa5940a8c0f00af917ee4bb1f4bab5
Author: John Ralls <jralls at ceridwen.us>
Date: Thu Dec 3 13:20:39 2015 -0800
Restore price source_name list compatibility with PriceSource enum.
diff --git a/src/engine/gnc-pricedb.c b/src/engine/gnc-pricedb.c
index 88eef3d..75e23d0 100644
--- a/src/engine/gnc-pricedb.c
+++ b/src/engine/gnc-pricedb.c
@@ -104,7 +104,7 @@ gnc_price_init(GNCPrice* price)
* changes will affect backward data compatibility.
* The last two values, temporary and invalid, are *not* used.
*/
-static const char* source_names[] =
+static const char* source_names[static_cast<size_t>(PRICE_SOURCE_INVALID)] =
{
/* sync with price_to_gui in dialog-price-editor.c */
"user:price-editor",
@@ -115,6 +115,7 @@ static const char* source_names[] =
"user:xfer-dialog",
"user:split-register",
"user:stock-split",
+ "user:invoice-post", /* Retained for backwards compatibility */
"temporary",
"invalid"
};
Summary of changes:
src/engine/gnc-pricedb.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
More information about the gnucash-changes
mailing list