slightly simpler log escaping