| 402 | }; |
| 403 | #endif |
| 404 | int |
| 405 | sys_getfsstat(struct thread *td, struct getfsstat_args *uap) |
| 406 | { |
| 407 | size_t count; |
| 408 | int error; |
| 409 | |
| 410 | if (uap->bufsize < 0 || uap->bufsize > SIZE_MAX) |
| 411 | return (EINVAL); |
| 412 | error = kern_getfsstat(td, &uap->buf, uap->bufsize, &count, |
| 413 | UIO_USERSPACE, uap->mode); |
| 414 | if (error == 0) |
| 415 | td->td_retval[0] = count; |
| 416 | return (error); |
| 417 | } |
| 418 | |
| 419 | /* |
| 420 | * If (bufsize > 0 && bufseg == UIO_SYSSPACE) |
nothing calls this directly
no test coverage detected