lib: replace one case switch with if operator
Current "switch" operator with one case replace with the "if" operator, because every switch statement shall have at least two case-clauses. Found as a coding guideline violation (MISRA R16.1) by static coding scanning tool. Signed-off-by: Maksim Masalski <maksim.masalski@intel.com>
This commit is contained in:
parent
a61edd480d
commit
9eab89ff20
1 changed files with 1 additions and 2 deletions
|
@ -304,8 +304,7 @@ int fcntl(int fd, int cmd, ...)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Handle fdtable commands. */
|
/* Handle fdtable commands. */
|
||||||
switch (cmd) {
|
if (cmd == F_DUPFD) {
|
||||||
case F_DUPFD:
|
|
||||||
/* Not implemented so far. */
|
/* Not implemented so far. */
|
||||||
errno = EINVAL;
|
errno = EINVAL;
|
||||||
return -1;
|
return -1;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue