summaryrefslogtreecommitdiff
path: root/src/py_post.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2009-11-12 05:10:21 -0500
committerJohn Wiegley <johnw@newartisans.com>2009-11-12 05:11:09 -0500
commitf217e50ab69b72f4c490d1a578617af637ffb4d6 (patch)
treeb3a2affabe34534b16b0a494ecb59df5960c884d /src/py_post.cc
parent86daa41a9087007ca507f956ed1dfc47efce9fed (diff)
downloadfork-ledger-f217e50ab69b72f4c490d1a578617af637ffb4d6.tar.gz
fork-ledger-f217e50ab69b72f4c490d1a578617af637ffb4d6.tar.bz2
fork-ledger-f217e50ab69b72f4c490d1a578617af637ffb4d6.zip
Set call policies for accessing post.xdata.account
Diffstat (limited to 'src/py_post.cc')
-rw-r--r--src/py_post.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/py_post.cc b/src/py_post.cc
index 80e7ee52..8aabea28 100644
--- a/src/py_post.cc
+++ b/src/py_post.cc
@@ -115,8 +115,10 @@ void export_post()
make_getter(&post_t::xdata_t::datetime),
make_setter(&post_t::xdata_t::datetime))
.add_property("account",
- make_getter(&post_t::xdata_t::account),
- make_setter(&post_t::xdata_t::account))
+ make_getter(&post_t::xdata_t::account,
+ return_internal_reference<>()),
+ make_setter(&post_t::xdata_t::account,
+ with_custodian_and_ward<1, 2>()))
.add_property("sort_values",
make_getter(&post_t::xdata_t::sort_values),
make_setter(&post_t::xdata_t::sort_values))