| 7803 | buf_free(&frag); |
| 7804 | free(raw); |
| 7805 | return ok; |
| 7806 | } |
| 7807 | |
| 7808 | static bool openai_tool_emit_param_prefix(int fd, const request *r, const char *id, |
| 7809 | openai_tool_stream *ts, |
| 7810 | const char *name, bool is_string) { |
| 7811 | buf frag = {0}; |
| 7812 | if (ts->first_param) ts->first_param = false; |
| 7813 | else buf_putc(&frag, ','); |
| 7814 | json_escape(&frag, name ? name : ""); |
| 7815 | buf_putc(&frag, ':'); |
| 7816 | if (is_string) buf_putc(&frag, '"'); |
| 7817 | bool ok = openai_tool_emit_args_fragment(fd, r, id, ts, frag.ptr ? frag.ptr : "", frag.len); |
| 7818 | buf_free(&frag); |
no outgoing calls
no test coverage detected