xselinux: don't pass a NULL key string to selabel_lookup().

This commit is contained in:
Eamon Walsh 2008-11-25 18:18:46 -05:00
parent c8472a7444
commit 2538fc0d89

View File

@ -474,7 +474,7 @@ SELinuxLabelClient(ClientPtr client)
/* Try to get a context from the socket */ /* Try to get a context from the socket */
if (fd < 0 || getpeercon(fd, &ctx) < 0) { if (fd < 0 || getpeercon(fd, &ctx) < 0) {
/* Otherwise, fall back to a default context */ /* Otherwise, fall back to a default context */
if (selabel_lookup(label_hnd, &ctx, NULL, SELABEL_X_CLIENT) < 0) if (selabel_lookup(label_hnd, &ctx, "remote", SELABEL_X_CLIENT) < 0)
FatalError("SELinux: failed to look up remote-client context\n"); FatalError("SELinux: failed to look up remote-client context\n");
} }