mess822x 1.23
mess822x
Loading...
Searching...
No Matches
822header.c
Go to the documentation of this file.
1#include "buffer.h"
2#include "logmsg.h"
3#include "getln.h"
4#include "mess822.h"
5#include "exit.h"
6
7#define WHO "822header"
8
9stralloc line = {0};
11
12int main(int argc,char **argv)
13{
14 for (;;) {
15 if (getln(buffer_0,&line,&match,'\n') == -1)
16 logmsg(WHO,111,FATAL,"unable to read input: ");
17 if (!mess822_ok(&line)) break;
18 buffer_put(buffer_1,line.s,line.len);
19 if (!match) break;
20 }
21
22 buffer_flush(buffer_1);
23 _exit(0);
24}
int main()
Definition: 822print.c:351
int mess822_ok(stralloc *)
Definition: mess822_ok.c:4
stralloc line
Definition: 822header.c:9
int match
Definition: 822header.c:10
#define WHO
Definition: 822header.c:7