#2462 assigned defect

shared/gpio.c possible memory leaks

Reported by: Gedare Bloom Owned by: Needs Funding
Priority: normal Milestone: Indefinite
Component: unspecified Version: 5
Severity: normal Keywords:
Cc: Blocked By:


rtems_gpio_enable_interrupt() in libbsp/shared/gpio.c should free the interrupt_state in case of a failure to rtems_gpio_interrupt_handler_install.

Also, the "if ( threaded_handling ) {" section the two error paths that return RTEMS_UNSATISFIED should undo the rtems_gpio_interrupt_handler_install of the pin handler and also free the interrupt_state.

Change History (3)

comment:1 Changed on Nov 9, 2015 at 6:46:21 PM by Gedare Bloom

Version: 4.114.12

comment:2 Changed on Nov 11, 2015 at 3:56:13 PM by Gedare Bloom <gedare@…>

In f8bdd12a48d82a26cd9ddb84bdfa1544a4592e0d/rtems:

gpio: free memory in error path

Updates #2462.

comment:3 Changed on Feb 15, 2017 at 2:20:42 PM by Sebastian Huber

Milestone: 4.12Indefinite
Owner: set to Needs Funding
Status: newassigned
Note: See TracTickets for help on using tickets.