Fix incorrect initialization of pthread_once variable.

This fixes a startup crash on Mac OS X, and should be safer on other
platforms too.