summaryrefslogtreecommitdiff
path: root/lib/hier_block.cpp
diff options
context:
space:
mode:
authorJosh Blum2013-04-03 23:09:49 -0700
committerJosh Blum2013-04-03 23:09:49 -0700
commit0651aff49ae7e066bc301faeecfbd519c4743849 (patch)
tree540884afb2ce0186ce951258359c8effb6ed9aa6 /lib/hier_block.cpp
parent3e0943d0e61b11cdd6b0b2dd7d0815a64e63725d (diff)
downloadsandhi-0651aff49ae7e066bc301faeecfbd519c4743849.tar.gz
sandhi-0651aff49ae7e066bc301faeecfbd519c4743849.tar.bz2
sandhi-0651aff49ae7e066bc301faeecfbd519c4743849.zip
gras: figured out how to do the python reference
Diffstat (limited to 'lib/hier_block.cpp')
-rw-r--r--lib/hier_block.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/hier_block.cpp b/lib/hier_block.cpp
index 4c0aef3..ab474c5 100644
--- a/lib/hier_block.cpp
+++ b/lib/hier_block.cpp
@@ -40,8 +40,11 @@ void HierBlock::disconnect(const Element &elem)
static Apology::Wax get_ref(const Element &elem)
{
- boost::shared_ptr<Element> shared_self = elem.weak_self.lock();
- if (shared_self) return shared_self;
+ if (elem.weak_self)
+ {
+ boost::shared_ptr<void> shared_self = elem.weak_self->lock();
+ if (shared_self) return shared_self;
+ }
return elem;
}