diff options
author | Ryan Long <ryan.long@oarcorp.com> | 2021-02-19 17:30:13 -0500 |
---|---|---|
committer | Joel Sherrill <joel@rtems.org> | 2021-02-26 16:56:07 -0600 |
commit | e5e58da6dfbdfa78ad499c2f52ec53c88538aa1c (patch) | |
tree | 9c9c4a09ec12bae91cbc96928508018e59f59b0b | |
parent | record-client.c: Fix Unchecked return value (CID #1456677) (diff) | |
download | rtems-e5e58da6dfbdfa78ad499c2f52ec53c88538aa1c.tar.bz2 |
getgrent.c: Fix Unchecked return value error (CID #1459004)
CID 1459004: Unchecked return value in endgrent().
Closes #4261
-rw-r--r-- | cpukit/libcsupport/src/getgrent.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cpukit/libcsupport/src/getgrent.c b/cpukit/libcsupport/src/getgrent.c index b358cb947c..de564304d4 100644 --- a/cpukit/libcsupport/src/getgrent.c +++ b/cpukit/libcsupport/src/getgrent.c @@ -95,6 +95,7 @@ void setgrent(void) void endgrent(void) { grp_context *ctx = grp_get_context(); + int sc; if (ctx == NULL) return; @@ -104,5 +105,6 @@ void endgrent(void) } free(ctx); - pthread_setspecific(grp_key, NULL); + sc = pthread_setspecific(grp_key, NULL); + _Assert_Unused_variable_equals(sc, 0); } |