From 1ba7e8fe22892fe590b94ed7fb1bf9af6588e5d0 Mon Sep 17 00:00:00 2001 From: Marian Buschsieweke Date: Tue, 29 Oct 2019 21:50:39 +0100 Subject: [PATCH] sys/luid: Added postcondition to luid_get() Stated the obvious in the doc: Altering the LUID returned by luid_get() breaks the guarantee that it is locally unique, as it than could collide with other LUIDs returned by luid_get(). --- sys/include/luid.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/include/luid.h b/sys/include/luid.h index 5ad2857bff..211bab20fe 100644 --- a/sys/include/luid.h +++ b/sys/include/luid.h @@ -75,6 +75,8 @@ extern "C" { * byte. * * @note The resulting LUID will repeat after 255 calls. + * @post The generated LUID must be used unchanged, as it could collide with + * other LUIDs if altered. * * @param[out] buf memory location to copy the LUID into. MUST be able to * hold at least @p len bytes