[riot-commits] [RIOT-OS/RIOT] 892370: cpu/stm32/qdec: test null callback pointer (#14125)

Gilles DOFFE noreply at github.com
Fri Jul 10 15:06:10 CEST 2020


  Branch: refs/heads/master
  Home:   https://github.com/RIOT-OS/RIOT
  Commit: 892370121ded21733f2a10b35563646f2472cc74
      https://github.com/RIOT-OS/RIOT/commit/892370121ded21733f2a10b35563646f2472cc74
  Author: Gilles DOFFE <g.doffe at gmail.com>
  Date:   2020-07-10 (Fri, 10 Jul 2020)

  Changed paths:
    M cpu/stm32/periph/qdec.c

  Log Message:
  -----------
  cpu/stm32/qdec: test null callback pointer (#14125)

cpu/stm32/qdec: test if callback pointer is set

Callback pointer is not tested and could result in a hard fault
if the pointer is NULL.
Thus only activate interrupt if a callback provided.

Signed-off-by: Gilles DOFFE <g.doffe at gmail.com>




More information about the commits mailing list