diff options
| author | Alejandro Colomar <alx@kernel.org> | 2023-01-26 00:24:12 +0100 |
|---|---|---|
| committer | Alejandro Colomar <alx@kernel.org> | 2023-01-26 01:01:55 +0100 |
| commit | 0e55b0d51139c262696e1b623ef889f08ddda0cf (patch) | |
| tree | abbf9566a678e36e9b40fda6113219562eba43ae | |
| parent | 6d90fc705fef115879f7b4f063ad94c5cc143417 (diff) | |
| download | man-pages-0e55b0d51139c262696e1b623ef889f08ddda0cf.tar.gz | |
pthread_setschedparam.3: EXAMPLES: Don't assign unused value
We're not reading the value after it's set. And I just checked that
that function can't fail for reasonable input.
Reported-by: cppcheck(1)
Reported-by: `make lint-c-cppcheck`
Signed-off-by: Alejandro Colomar <alx@kernel.org>
| -rw-r--r-- | man3/pthread_setschedparam.3 | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/man3/pthread_setschedparam.3 b/man3/pthread_setschedparam.3 index 63b796dec4..70aa2d3768 100644 --- a/man3/pthread_setschedparam.3 +++ b/man3/pthread_setschedparam.3 @@ -403,7 +403,7 @@ main(int argc, char *argv[]) printf("Scheduler settings in \(aqattr\(aq\en"); display_sched_attr(policy, ¶m); - s = pthread_attr_getinheritsched(&attr, &inheritsched); + pthread_attr_getinheritsched(&attr, &inheritsched); printf(" inheritsched is %s\en", (inheritsched == PTHREAD_INHERIT_SCHED) ? "INHERIT" : (inheritsched == PTHREAD_EXPLICIT_SCHED) ? "EXPLICIT" : |
