MCPcopy Create free account
hub / github.com/coreutils/coreutils / get_labeling_handle

Function get_labeling_handle

src/install.c:300–313  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

298}
299
300static struct selabel_handle *
301get_labeling_handle (void)
302{
303 static bool initialized;
304 static struct selabel_handle *hnd;
305 if (!initialized)
306 {
307 initialized = true;
308 hnd = selabel_open (SELABEL_CTX_FILE, NULL, 0);
309 if (!hnd)
310 error (0, errno, _("warning: security labeling handle failed"));
311 }
312 return hnd;
313}
314
315/* Modify file context to match the specified policy.
316 If an error occurs the file will remain with the default directory

Callers 2

setdefaultfileconFunction · 0.85
mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected