Skip to content

Commit

Permalink
Merge pull request #50 from mikudeko/master
Browse files Browse the repository at this point in the history
Fix GetProperty always returning 'VALUE'
  • Loading branch information
mmlb authored Nov 3, 2016
2 parents 8b82d2e + effac78 commit c0224de
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion zfs.go
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ func (d *Dataset) SetProperty(key, val string) error {
// A full list of available ZFS properties may be found here:
// https://www.freebsd.org/cgi/man.cgi?zfs(8).
func (d *Dataset) GetProperty(key string) (string, error) {
out, err := zfs("get", key, d.Name)
out, err := zfs("get", "-H", key, d.Name)
if err != nil {
return "", err
}
Expand Down
2 changes: 1 addition & 1 deletion zfs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ func TestDatasetGetProperty(t *testing.T) {

prop, err = ds.GetProperty("compression")
ok(t, err)
equals(t, "VALUE", prop)
equals(t, "off", prop)
})
}

Expand Down

0 comments on commit c0224de

Please sign in to comment.