Use warn() instead of perror().
This commit is contained in:
parent
f9d9941f2d
commit
2c61418d05
@ -298,11 +298,11 @@ udom_open(const char *path, int flags)
|
||||
switch(flags & O_ACCMODE) {
|
||||
case O_RDONLY:
|
||||
if (shutdown(fd, SHUT_WR) == -1)
|
||||
perror("cat");
|
||||
warn(NULL);
|
||||
break;
|
||||
case O_WRONLY:
|
||||
if (shutdown(fd, SHUT_RD) == -1)
|
||||
perror("cat");
|
||||
warn(NULL);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
@ -785,7 +785,7 @@ label(KINFO *k, VARENT *ve)
|
||||
v = ve->var;
|
||||
string = NULL;
|
||||
if (mac_prepare_process_label(&proclabel) == -1) {
|
||||
perror("mac_prepare_process_label");
|
||||
warn("mac_prepare_process_label");
|
||||
goto out;
|
||||
}
|
||||
error = mac_get_pid(k->ki_p->ki_pid, proclabel);
|
||||
@ -811,7 +811,7 @@ s_label(KINFO *k)
|
||||
int error, size = 0;
|
||||
|
||||
if (mac_prepare_process_label(&proclabel) == -1) {
|
||||
perror("mac_prepare_process_label");
|
||||
warn("mac_prepare_process_label");
|
||||
return (0);
|
||||
}
|
||||
error = mac_get_pid(k->ki_p->ki_pid, proclabel);
|
||||
|
Loading…
Reference in New Issue
Block a user