comments thread safety

@peter828