mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-05 09:14:03 +00:00
Use warn() instead of perror().
This commit is contained in:
parent
f9d9941f2d
commit
2c61418d05
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=132433
@ -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