[RTEMS Project] #4281: main_chmod.c: Unchecked return value from library error spotted by Coverity

RTEMS trac trac at rtems.org
Tue Mar 2 14:30:30 UTC 2021


#4281: main_chmod.c: Unchecked return value from library error spotted by Coverity
------------------------+--------------------
  Reporter:  Ryan Long  |      Owner:  (none)
      Type:  defect     |     Status:  new
  Priority:  normal     |  Milestone:  6.1
 Component:  lib        |    Version:  6
  Severity:  normal     |   Keywords:
Blocked By:             |   Blocking:
------------------------+--------------------
 CID 1063856: Unchecked return value from library in
 rtems_shell_main_chmod().

 {{{
 55  for (n=2 ; n < argc ; n++)
   CID 1063856 (#1 of 1): Unchecked return value from library
 (CHECKED_RETURN)4. check_return: Calling chmod(argv[n++], mode) without
 checking return value. This library function may fail and return an error
 code. [Note: The source code implementation of the function has been
 overridden by a builtin model.]
 56    chmod(argv[n++], mode);
 57
 58  return 0;
 59}
 }}}

--
Ticket URL: <http://devel.rtems.org/ticket/4281>
RTEMS Project <http://www.rtems.org/>
RTEMS Project


More information about the bugs mailing list