static json_t *read_pdu_into_json(w_jbuffer_t *jr, int fd, json_error_t *jerr) { if (jr->pdu_type == is_json_compact) { return read_json_pdu(jr, fd, jerr); } return read_bser_pdu(jr, fd, jerr); }
static json_t *read_pdu_into_json(w_jbuffer_t *jr, w_stm_t stm, json_error_t *jerr) { switch (jr->pdu_type) { case is_json_compact: return read_json_pdu(jr, stm, jerr); case is_json_pretty: return read_json_pretty_pdu(jr, stm, jerr); default: return read_bser_pdu(jr, stm, jerr); } }