full diff: https://github.com/opencontainers/selinux/compare/v1.2...v1.2.1
brings in opencontainers/selinux#49 Ignore attempts to setLabels "" on SELinux disabled systems
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
| ... | ... |
@@ -161,4 +161,4 @@ github.com/morikuni/aec 39771216ff4c63d11f5e604076f9c45e8be1067b |
| 161 | 161 |
# metrics |
| 162 | 162 |
github.com/docker/go-metrics d466d4f6fd960e01820085bd7e1a24426ee7ef18 |
| 163 | 163 |
|
| 164 |
-github.com/opencontainers/selinux 9e2c5215628a2567782777efb2049f385484f918 # v1.2 |
|
| 164 |
+github.com/opencontainers/selinux 0bb7b9fa9ba5c1120e9d22caed4961fca4228408 # v1.2.1 |
| ... | ... |
@@ -333,6 +333,11 @@ func writeCon(fpath string, val string) error {
|
| 333 | 333 |
if fpath == "" {
|
| 334 | 334 |
return ErrEmptyPath |
| 335 | 335 |
} |
| 336 |
+ if val == "" {
|
|
| 337 |
+ if !GetEnabled() {
|
|
| 338 |
+ return nil |
|
| 339 |
+ } |
|
| 340 |
+ } |
|
| 336 | 341 |
|
| 337 | 342 |
out, err := os.OpenFile(fpath, os.O_WRONLY, 0) |
| 338 | 343 |
if err != nil {
|