* Send code/data. */
| 260 | * Send code/data. |
| 261 | */ |
| 262 | void e9tool::sendCode(FILE *out, const char *code) |
| 263 | { |
| 264 | fputc('[', out); |
| 265 | size_t len = strlen(code); |
| 266 | while (len > 0 && isspace(code[len-1])) |
| 267 | len--; |
| 268 | if (len > 0 && code[len-1] == ',') |
| 269 | len--; |
| 270 | fwrite(code, sizeof(char), len, out); |
| 271 | fputc(']', out); |
| 272 | } |
| 273 | |
| 274 | /* |
| 275 | * Send raw bytes. |