minor corrections to logging code