diff --git a/watchman/PDU.cpp b/watchman/PDU.cpp index 8d47556d553d..3166069f753b 100644 --- a/watchman/PDU.cpp +++ b/watchman/PDU.cpp @@ -581,18 +581,18 @@ ResultErrno PduBuffer::jsonEncodeToStream( } ResultErrno PduBuffer::pduEncodeToStream( - PduFormat format, + PduFormat format_2, const json_ref& json, watchman_stream* stm) { - switch (format.type) { + switch (format_2.type) { case is_json_compact: return jsonEncodeToStream(json, stm, JSON_COMPACT); case is_json_pretty: return jsonEncodeToStream(json, stm, JSON_INDENT(4)); case is_bser: - return bserEncodeToStream(1, format.capabilities, json, stm); + return bserEncodeToStream(1, format_2.capabilities, json, stm); case is_bser_v2: - return bserEncodeToStream(2, format.capabilities, json, stm); + return bserEncodeToStream(2, format_2.capabilities, json, stm); case need_data: default: return EINVAL;