git: 540b4791d8c9 - stable/13 - cap_fileargs: silence warnings of unused variable
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 23 Mar 2022 15:51:39 UTC
The branch stable/13 has been updated by pstef: URL: https://cgit.FreeBSD.org/src/commit/?id=540b4791d8c93e1d2c8963d38992375c83ac6d27 commit 540b4791d8c93e1d2c8963d38992375c83ac6d27 Author: Mariusz Zaborski <oshogbo@FreeBSD.org> AuthorDate: 2022-03-20 10:17:31 +0000 Commit: Piotr Pawel Stefaniak <pstef@FreeBSD.org> CommitDate: 2022-03-23 15:45:06 +0000 cap_fileargs: silence warnings of unused variable We still want to fetch the variable just to verify that the interface is right. (cherry picked from commit 1e9ce60a6d758ddf5392e96e886fd815694dd66b) --- lib/libcasper/services/cap_fileargs/cap_fileargs.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/libcasper/services/cap_fileargs/cap_fileargs.c b/lib/libcasper/services/cap_fileargs/cap_fileargs.c index ecab23004fcf..2e501a860ee6 100644 --- a/lib/libcasper/services/cap_fileargs/cap_fileargs.c +++ b/lib/libcasper/services/cap_fileargs/cap_fileargs.c @@ -275,8 +275,7 @@ fileargs_cinitnv(cap_channel_t *cas, nvlist_t *limits) { cap_channel_t *chann; fileargs_t *fa; - int serrno, ret; - int flags, operations; + int flags, ret, serrno; assert(cas != NULL); @@ -294,7 +293,7 @@ fileargs_cinitnv(cap_channel_t *cas, nvlist_t *limits) } flags = nvlist_get_number(limits, "flags"); - operations = nvlist_get_number(limits, "operations"); + (void)nvlist_get_number(limits, "operations"); /* Limits are consumed no need to free them. */ ret = cap_limit_set(chann, limits);