| 1096 | } |
| 1097 | |
| 1098 | static int ui_log_count_char(const char *s, char ch) { |
| 1099 | int n = 0; |
| 1100 | for (; *s; s++) { |
| 1101 | if (*s == ch) |
| 1102 | n++; |
| 1103 | } |
| 1104 | return n; |
| 1105 | } |
| 1106 | |
| 1107 | static int ui_log_post(int port, const char *body, char *resp, size_t respsz) { |
| 1108 | size_t cap = strlen(body) + 512; |