* systemdDestroyConn is copied from containerd/cgroups/systemd.go file, that has the following license: Copyright The containerd Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtai
(path string, c *systemdDbus.Conn)
| 68 | limitations under the License. |
| 69 | */ |
| 70 | func systemdDestroyConn(path string, c *systemdDbus.Conn) error { |
| 71 | name := filepath.Base(path) |
| 72 | |
| 73 | ch := make(chan string) |
| 74 | _, err := c.StopUnitContext(context.TODO(), name, "replace", ch) |
| 75 | if err != nil { |
| 76 | return err |
| 77 | } |
| 78 | <-ch |
| 79 | return nil |
| 80 | } |
no outgoing calls
no test coverage detected
searching dependent graphs…