mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
d167cb3af8
The mapping from thread state codes to a human readable string in the PS modules has to be maintained manually. There is a very real possibility for it to get out of sync with the actual defined states, which would cause a crash when a lookup with an out of bounds index is performed. Also, because of the way the array is defined, there could be gaps (which will be filled by nulls). This patch replaces the array looukup by a function that checks bounds and also triggers an assertion so that the issue can be caught during development. |
||
---|---|---|
.. | ||
Makefile | ||
ps.c |