blob: ad2a6b7a43b9fe717d17fb9d8533c549d0255be7 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
/*
* Copyright (c) 2015, Juniper Networks, Inc.
* All rights reserved.
* This SOFTWARE is licensed under the LICENSE provided in the
* ../Copyright file. By downloading, installing, copying, or otherwise
* using the SOFTWARE, you agree to be bound by the terms of that
* LICENSE.
* Phil Shafer, August 2015
*/
#include "xo.h"
#include "xo_encoder.h"
static int
test_handler (XO_ENCODER_HANDLER_ARGS)
{
flags &= ~XOF_UTF8; /* Skip this flag, since it depends on terminal */
printf("op %s: [%s] [%s] [%#llx]\n", xo_encoder_op_name(op),
name ?: "", value ?: "", (unsigned long long) flags);
return 0;
}
int
xo_encoder_library_init (XO_ENCODER_INIT_ARGS)
{
arg->xei_version = XO_ENCODER_VERSION;
arg->xei_handler = test_handler;
return 0;
}
|