1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

sys/pm_layered: pm_get_blocker = instead of memcopy -ease readability

This commit is contained in:
Karl Fessel 2022-11-04 16:52:32 +01:00
parent 5447203921
commit 72a1e93eed

View File

@ -19,7 +19,6 @@
*/
#include <assert.h>
#include <string.h>
#include "board.h"
#include "irq.h"
@ -102,7 +101,7 @@ pm_blocker_t pm_get_blocker(void)
pm_blocker_t result;
unsigned state = irq_disable();
memcpy(&result, &pm_blocker, sizeof(result));
result = pm_blocker;
irq_restore(state);
return result;