Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Destroy Attributes's handle before its parent_link #662

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/h5cpp/attribute/attribute.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ namespace hdf5 {
namespace attribute {

Attribute::Attribute(ObjectHandle &&handle,const node::Link &parent_link):
handle_(std::move(handle)),
parent_link_(parent_link)
parent_link_(parent_link),
handle_(std::move(handle))
{
}

Expand Down
2 changes: 1 addition & 1 deletion src/h5cpp/attribute/attribute.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -203,8 +203,8 @@ class DLL_EXPORT Attribute
void read(T &data,const datatype::Datatype &mem_type) const;

private:
ObjectHandle handle_;
node::Link parent_link_;
ObjectHandle handle_;

template<typename T>
void read(T &data,const datatype::Datatype &mem_type, const datatype::Datatype &file_type) const;
Expand Down
Loading