The enum change from uint8_t to an int avoids uninitialized bytes, which led to valgrind warnings (no error though).