Skip to content

Commit 280dc07

Browse files
committed
fix typo in cgroup1/opts/ initConfig
Signed-off-by: Anuj Singh <singholt@amazon.com>
1 parent 8e9e14c commit 280dc07

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

cgroup1/cgroup.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ func New(path Path, resources *specs.LinuxResources, opts ...InitOpts) (Cgroup,
4141
return nil, err
4242
}
4343
}
44-
subsystems, err := config.hiearchy()
44+
subsystems, err := config.hierarchy()
4545
if err != nil {
4646
return nil, err
4747
}
@@ -79,7 +79,7 @@ func Load(path Path, opts ...InitOpts) (Cgroup, error) {
7979
}
8080
}
8181
var activeSubsystems []Subsystem
82-
subsystems, err := config.hiearchy()
82+
subsystems, err := config.hierarchy()
8383
if err != nil {
8484
return nil, err
8585
}

cgroup1/opts.go

+3-3
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,13 @@ type InitOpts func(*InitConfig) error
3636
type InitConfig struct {
3737
// InitCheck can be used to check initialization errors from the subsystem
3838
InitCheck InitCheck
39-
hiearchy Hierarchy
39+
hierarchy Hierarchy
4040
}
4141

4242
func newInitConfig() *InitConfig {
4343
return &InitConfig{
4444
InitCheck: RequireDevices,
45-
hiearchy: Default,
45+
hierarchy: Default,
4646
}
4747
}
4848

@@ -66,7 +66,7 @@ func RequireDevices(s Subsystem, _ Path, _ error) error {
6666
// The default list is coming from /proc/self/mountinfo.
6767
func WithHiearchy(h Hierarchy) InitOpts {
6868
return func(c *InitConfig) error {
69-
c.hiearchy = h
69+
c.hierarchy = h
7070
return nil
7171
}
7272
}

cgroup1/v1.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ func Default() ([]Subsystem, error) {
4545
}
4646

4747
// v1MountPoint returns the mount point where the cgroup
48-
// mountpoints are mounted in a single hiearchy
48+
// mountpoints are mounted in a single hierarchy
4949
func v1MountPoint() (string, error) {
5050
f, err := os.Open("/proc/self/mountinfo")
5151
if err != nil {

0 commit comments

Comments
 (0)