From ee9aac43ac72a82367506b70b1e0e9be5a467ce9 Mon Sep 17 00:00:00 2001 From: Didier Roche Date: Mon, 6 Apr 2020 15:58:23 +0200 Subject: [PATCH] Fix dataset to have to correct type The parent type was used before if the dataset was opened via openChildren(). --- zfs.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zfs.go b/zfs.go index 6b6a013..18de99d 100644 --- a/zfs.go +++ b/zfs.go @@ -59,7 +59,7 @@ func (d *Dataset) openChildren() (err error) { list := C.dataset_list_children(d.list) for list != nil { dataset := Dataset{list: list} - dataset.Type = DatasetType(C.dataset_type(d.list)) + dataset.Type = DatasetType(C.dataset_type(list)) dataset.Properties = make(map[Prop]Property) err = dataset.ReloadProperties() if err != nil {