Red–black tree implementation for C99