gnucash stable: Multiple changes pushed
John Ralls
jralls at code.gnucash.org
Sun Jun 2 17:40:56 EDT 2024
Updated via https://github.com/Gnucash/gnucash/commit/1ad2e66a (commit)
via https://github.com/Gnucash/gnucash/commit/c4d44ea0 (commit)
from https://github.com/Gnucash/gnucash/commit/8106ffb8 (commit)
commit 1ad2e66aac608c528a5a4dccf4d576924b6e00b0
Merge: 8106ffb84b c4d44ea024
Author: John Ralls <jralls at ceridwen.us>
Date: Sun Jun 2 14:40:21 2024 -0700
Merge Daniel Harding's Bug799324 into stable.
commit c4d44ea02411b44613d0069b6cbbd9948f48274b
Author: Daniel Harding <dharding at living180.net>
Date: Sun Jun 2 14:54:42 2024 +0300
Bug 799324 - Invalid free in gvalue_from_kvp_value()
As of ddc3f28899c71579abd9b2bd822baa6b95fc41d6, gvalue_from_kvp_value()
takes a GValue pointer from the caller, which in some cases points to
memory on the stack. If that is the case and the code also hits the
default case in the switch statement, the unconditional g_slice_free()
call will attempt to free stack memory, causing the program to abort.
Fix by requiring the caller to always pass in a valid GValue pointer,
making the caller responsible for freeing it if necessary. This also
means that it is no longer necessary for gvalue_from_kvp_value() to
return a value, so make it a void function.
Summary of changes:
libgnucash/engine/kvp-frame.cpp | 12 +++---------
libgnucash/engine/kvp-value.hpp | 4 ++--
libgnucash/engine/qofinstance.cpp | 4 ++--
3 files changed, 7 insertions(+), 13 deletions(-)
More information about the gnucash-patches
mailing list