diff options
author | Mike Frysinger <vapier@google.com> | 2018-01-20 13:42:10 -0500 |
---|---|---|
committer | Mike Frysinger <vapier@google.com> | 2018-01-24 09:36:21 +0000 |
commit | 5ef22ca4043f0dde4ac2e73a46321e1c03ac9541 (patch) | |
tree | 5cf7c3758c5e6b56d22611666f7dd2d8159cc9f8 /minijail0_cli.h | |
parent | 37c8e3c55c1c96b49a56012d10f7f0b356e7bfd9 (diff) | |
download | minijail-5ef22ca4043f0dde4ac2e73a46321e1c03ac9541.tar.gz |
split minijail0 cli parsers into a sep module
This will let us unittest them easily. The only thing this CL has done
is move all the non-main funcs from minijail0.c to minijail0_cli.c.
Bug: None
Test: `make check` passes
Change-Id: I2be5cf2097d1f8d15270595f5200c872a0a551c4
Diffstat (limited to 'minijail0_cli.h')
-rw-r--r-- | minijail0_cli.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/minijail0_cli.h b/minijail0_cli.h new file mode 100644 index 0000000..d4eb440 --- /dev/null +++ b/minijail0_cli.h @@ -0,0 +1,26 @@ +/* Copyright 2018 The Chromium OS Authors. All rights reserved. + * Use of this source code is governed by a BSD-style license that can be + * found in the LICENSE file. + * + * Helpers for the minijail0 program. Split out for unittesting. + */ + +#ifndef MINIJAIL_MINIJAIL0_CLI_H_ +#define MINIJAIL_MINIJAIL0_CLI_H_ + +#include "elfparse.h" + +#ifdef __cplusplus +extern "C" { +#endif + +struct minijail; + +int parse_args(struct minijail *j, int argc, char * const argv[], + int *exit_immediately, ElfType *elftype); + +#ifdef __cplusplus +}; /* extern "C" */ +#endif + +#endif /* MINIJAIL_MINIJAIL0_CLI_H_ */ |