diff options
Diffstat (limited to 'ot_fmt.h')
| -rw-r--r-- | ot_fmt.h | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/ot_fmt.h b/ot_fmt.h deleted file mode 100644 index 214cbc4..0000000 --- a/ot_fmt.h +++ /dev/null | |||
| @@ -1,19 +0,0 @@ | |||
| 1 | /* This software was written by Dirk Engling <erdgeist@erdgeist.org> | ||
| 2 | It is considered beerware. Prost. Skol. Cheers or whatever. */ | ||
| 3 | |||
| 4 | #ifndef OT_FMT_H__ | ||
| 5 | #define OT_FMT_H__ | ||
| 6 | |||
| 7 | #include <stddef.h> | ||
| 8 | |||
| 9 | /* Appending to a cursor that walks a fixed buffer. Both take the cursor by | ||
| 10 | reference and advance it, so a reply is written as a run of statements and | ||
| 11 | no caller does pointer arithmetic of its own. */ | ||
| 12 | |||
| 13 | void fmt_append(char **cursor, const char *end, const char *format, ...) __attribute__((format(printf, 3, 4))); | ||
| 14 | |||
| 15 | /* Append raw bytes for the binary stretches of a bencoded reply. | ||
| 16 | Either everything is appended or nothing at all */ | ||
| 17 | void fmt_bytes(char **cursor, const char *end, const void *bytes, size_t length); | ||
| 18 | |||
| 19 | #endif | ||
