Artifact 0654040df9d84109f99feedbeb146cca5db51bb39944fb2ed262a7b191fcb55b:
- File mod/kstr/emitc.fn.c — part of check-in [927371b674] at 2019-10-31 03:44:25 on branch trunk — add usage display for parameters and command line switches for kcli_set, the structure used to define command line syntax for the parser; add more string & buffer functions (user: lexi, size: 295) [annotate] [blame] [check-ins using]
#include <k/type.h> #include <k/str.h> #include <k/io.h> kcond ksemitc(const char** array, sz bufsz, kiochan channel) { ubyte cache [sizeof(ksbuf) + bufsz]; ksbuf* out = ksbufmk(cache, channel, bufsz); kcond c = ksbufwrite(out, array); if (!kokay(c)) return c; return ksbufflush(out); }