Fix a valgrind bug in the new [ug]id2sid cache