Commit f2363e38 by S.Çağlar Onur Committed by Serge Hallyn

adjust include statements (v2)

Use "#include <somefile.h>" style for external or exported headers only. changes since v1: - adjusted formatting as Stéphane suggested Signed-off-by: 's avatarS.Çağlar Onur <caglar@10ur.org> Signed-off-by: 's avatarSerge Hallyn <serge.hallyn@ubuntu.com>
parent 23b9d428
......@@ -30,7 +30,7 @@
#include <unistd.h>
#include <libgen.h>
#include <lxc/lxccontainer.h>
#include <lxc/commands.h>
#include "lxc/commands.h"
#if LUA_VERSION_NUM < 502
#define luaL_newlib(L,l) (lua_newtable(L), luaL_register(L,NULL,l))
......
......@@ -25,7 +25,7 @@
#define _attach_h
#include <sys/types.h>
#include "attach_options.h"
#include <lxc/attach_options.h>
struct lxc_proc_context_info {
char *lsm_label;
......
......@@ -37,6 +37,7 @@
#include <libgen.h>
#include <linux/loop.h>
#include <dirent.h>
#include "lxc.h"
#include "config.h"
#include "conf.h"
......
......@@ -45,10 +45,9 @@
#include "conf.h"
#include "utils.h"
#include "bdev.h"
#include <lxc/log.h>
#include <lxc/cgroup.h>
#include <lxc/start.h>
#include "log.h"
#include "cgroup.h"
#include "start.h"
#if IS_BIONIC
#include <../include/lxcmntent.h>
......
......@@ -20,8 +20,8 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#include <lxc/lxc.h>
#include <lxc/log.h>
#include "lxc.h"
#include "log.h"
lxc_log_define(lxc_checkpoint, lxc);
......
......@@ -33,13 +33,12 @@
#include <malloc.h>
#include <stdlib.h>
#include <lxc/log.h>
#include <lxc/lxc.h>
#include <lxc/conf.h>
#include <lxc/start.h> /* for struct lxc_handler */
#include <lxc/utils.h>
#include <lxc/cgroup.h>
#include "log.h"
#include "lxc.h"
#include "conf.h"
#include "start.h" /* for struct lxc_handler */
#include "utils.h"
#include "cgroup.h"
#include "commands.h"
#include "console.h"
#include "confile.h"
......
......@@ -31,9 +31,8 @@
#include <sys/types.h>
#include <stdbool.h>
#include <lxc/list.h>
#include <lxc/start.h> /* for lxc_handler */
#include "list.h"
#include "start.h" /* for lxc_handler */
#if HAVE_SCMP_FILTER_CTX
typedef void * scmp_filter_ctx;
......
......@@ -41,9 +41,8 @@
#include "config.h"
#include "confile.h"
#include "utils.h"
#include <lxc/log.h>
#include <lxc/conf.h>
#include "log.h"
#include "conf.h"
#include "network.h"
#if HAVE_SYS_PERSONALITY_H
......
......@@ -22,7 +22,7 @@
*/
#include <stdio.h>
#include "attach_options.h"
#include <lxc/attach_options.h>
#ifndef _confile_h
#define _confile_h
......
......@@ -32,6 +32,7 @@
#include <termios.h>
#include <lxc/lxccontainer.h>
#include "log.h"
#include "conf.h"
#include "config.h"
......
......@@ -24,6 +24,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <sys/wait.h>
#include "error.h"
#include "log.h"
......
......@@ -34,9 +34,8 @@
#include "error.h"
#include "state.h"
#include "monitor.h"
#include <lxc/log.h>
#include <lxc/cgroup.h>
#include "log.h"
#include "cgroup.h"
lxc_log_define(lxc_freezer, lxc);
......
......@@ -26,6 +26,7 @@
#include <sys/stat.h>
#include <sys/mount.h>
#include <sys/apparmor.h>
#include "log.h"
#include "lsm/lsm.h"
......
......@@ -25,6 +25,7 @@
#include <sys/types.h>
#include <unistd.h>
#include <selinux/selinux.h>
#include "log.h"
#include "lsm/lsm.h"
......
......@@ -30,7 +30,7 @@ extern "C" {
#include <stddef.h>
#include <sys/select.h>
#include <sys/types.h>
#include <lxc/state.h>
#include "state.h"
struct lxc_msg;
struct lxc_conf;
......
......@@ -26,10 +26,10 @@
#include <libgen.h>
#include <sys/types.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/lxccontainer.h>
#include "lxc.h"
#include "log.h"
#include "arguments.h"
lxc_log_define(lxc_cgroup_ui, lxc_cgroup);
......
......@@ -30,10 +30,9 @@
#include <sys/types.h>
#include <fcntl.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/utils.h>
#include "lxc.h"
#include "log.h"
#include "utils.h"
#include "arguments.h"
#include "config.h"
#include "caps.h"
......
......@@ -27,12 +27,13 @@
#include <errno.h>
#include <ctype.h>
#include <lxc/lxccontainer.h>
#include "log.h"
#include "config.h"
#include "lxc.h"
#include "conf.h"
#include "state.h"
#include <lxc/lxccontainer.h>
lxc_log_define(lxc_clone, lxc);
......
......@@ -20,9 +20,11 @@
#include <stdio.h>
#include <string.h>
#include "config.h"
#include <lxc/lxccontainer.h>
#include "config.h"
struct lxc_config_items {
char *name;
const char *(*fn)(void);
......
......@@ -39,6 +39,7 @@
#include <sys/ioctl.h>
#include <lxc/lxccontainer.h>
#include "error.h"
#include "lxc.h"
#include "log.h"
......
......@@ -26,10 +26,9 @@
#include <fcntl.h>
#include <sys/types.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/bdev.h>
#include "lxc.h"
#include "log.h"
#include "bdev.h"
#include "arguments.h"
#include "utils.h"
......
......@@ -24,9 +24,8 @@
#include <unistd.h>
#include <sys/types.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include "lxc.h"
#include "log.h"
#include "arguments.h"
#include "utils.h"
......
......@@ -26,10 +26,11 @@
#include <libgen.h>
#include <string.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/lxccontainer.h>
#include "lxc.h"
#include "log.h"
#include "arguments.h"
lxc_log_define(lxc_freeze_ui, lxc_cgroup);
......
......@@ -29,11 +29,11 @@
#include <libgen.h>
#include <sys/types.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/utils.h>
#include <lxc/lxccontainer.h>
#include "lxc.h"
#include "log.h"
#include "utils.h"
#include "commands.h"
#include "arguments.h"
......
......@@ -26,6 +26,7 @@
#include <sys/param.h>
#include <stdlib.h>
#include <signal.h>
#include "commands.h"
#include "arguments.h"
#include "namespace.h"
......
......@@ -29,9 +29,9 @@
#include <sys/types.h>
#include <errno.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/monitor.h>
#include "lxc.h"
#include "log.h"
#include "monitor.h"
#include "arguments.h"
lxc_log_define(lxc_monitor_ui, lxc_monitor);
......
......@@ -38,11 +38,11 @@
#include <netinet/in.h>
#include <net/if.h>
#include <lxc/af_unix.h>
#include <lxc/log.h>
#include <lxc/mainloop.h>
#include <lxc/monitor.h>
#include <lxc/utils.h>
#include "af_unix.h"
#include "log.h"
#include "mainloop.h"
#include "monitor.h"
#include "utils.h"
#define CLIENTFDS_CHUNK 64
......
......@@ -17,8 +17,6 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
#include <lxc/lxccontainer.h>
#include <stdio.h>
#include <libgen.h>
#include <unistd.h>
......@@ -26,10 +24,11 @@
#include <sys/types.h>
#include <fcntl.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/bdev.h>
#include <lxc/lxccontainer.h>
#include "lxc.h"
#include "log.h"
#include "bdev.h"
#include "arguments.h"
#include "utils.h"
......
......@@ -40,10 +40,11 @@
#include <netinet/in.h>
#include <net/if.h>
#include <lxc/lxccontainer.h>
#include "log.h"
#include "caps.h"
#include "lxc.h"
#include <lxc/lxccontainer.h>
#include "conf.h"
#include "cgroup.h"
#include "utils.h"
......
......@@ -25,10 +25,10 @@
#include <unistd.h>
#include <sys/types.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/lxccontainer.h>
#include "lxc.h"
#include "log.h"
#include "arguments.h"
#include "commands.h"
#include "utils.h"
......
......@@ -25,10 +25,10 @@
#include <libgen.h>
#include <sys/types.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/lxccontainer.h>
#include "lxc.h"
#include "log.h"
#include "arguments.h"
lxc_log_define(lxc_unfreeze_ui, lxc_cgroup);
......
......@@ -45,6 +45,7 @@
#include <linux/rtnetlink.h>
#include <linux/sockios.h>
#include <sys/param.h>
#include "config.h"
#include "utils.h"
#include "network.h"
......
......@@ -38,6 +38,7 @@
#include <sched.h>
#include <pwd.h>
#include <grp.h>
#include "config.h"
#include "namespace.h"
#include "utils.h"
......
......@@ -28,9 +28,10 @@
#include <signal.h>
#include <sys/types.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/lxccontainer.h>
#include "lxc.h"
#include "log.h"
#include "arguments.h"
lxc_log_define(lxc_wait_ui, lxc_monitor);
......
......@@ -30,26 +30,28 @@
#include <fcntl.h>
#include <sched.h>
#include <dirent.h>
#include <sched.h>
#include <arpa/inet.h>
#include <libgen.h>
#include <lxc/lxccontainer.h>
#include <lxc/version.h>
#include "config.h"
#include "lxc.h"
#include "state.h"
#include <lxc/lxccontainer.h>
#include "conf.h"
#include "confile.h"
#include "console.h"
#include "cgroup.h"
#include "commands.h"
#include "version.h"
#include "log.h"
#include "bdev.h"
#include "utils.h"
#include "attach.h"
#include <lxc/utils.h>
#include <lxc/monitor.h>
#include <lxc/namespace.h>
#include <sched.h>
#include <arpa/inet.h>
#include <libgen.h>
#include "utils.h"
#include "monitor.h"
#include "namespace.h"
#include "lxclock.h"
#if HAVE_IFADDRS_H
......
......@@ -22,12 +22,13 @@
#ifndef __LXC_CONTAINER_H
#define __LXC_CONTAINER_H
#include "attach_options.h"
#include <malloc.h>
#include <semaphore.h>
#include <stdbool.h>
#include <stdlib.h>
#include <lxc/attach_options.h>
#ifdef __cplusplus
extern "C" {
#endif
......
......@@ -27,10 +27,12 @@
#include <fcntl.h>
#include <stdlib.h>
#include <pthread.h>
#include <lxc/utils.h>
#include <lxc/log.h>
#include <lxc/lxccontainer.h>
#include "utils.h"
#include "log.h"
#ifdef MUTEX_DEBUGGING
#include <execinfo.h>
#endif
......
......@@ -41,12 +41,11 @@
#include "error.h"
#include "af_unix.h"
#include <lxc/log.h>
#include <lxc/lxclock.h>
#include <lxc/state.h>
#include <lxc/monitor.h>
#include <lxc/utils.h>
#include "log.h"
#include "lxclock.h"
#include "state.h"
#include "monitor.h"
#include "utils.h"
lxc_log_define(lxc_monitor, lxc);
......
......@@ -26,7 +26,7 @@
#include <sys/param.h>
#include <sys/un.h>
#include <lxc/conf.h>
#include "conf.h"
typedef enum {
lxc_msg_state,
......
......@@ -31,7 +31,7 @@
#include "parse.h"
#include "config.h"
#include "utils.h"
#include <lxc/log.h>
#include "log.h"
lxc_log_define(lxc_parse, lxc);
......
......@@ -30,10 +30,10 @@
#include <errno.h>
#include <unistd.h>
#include <lxc/log.h>
#include <lxc/start.h> /* for struct lxc_handler */
#include <lxc/utils.h>
#include <lxc/error.h>
#include "log.h"
#include "start.h" /* for struct lxc_handler */
#include "utils.h"
#include "error.h"
lxc_log_define(lxc_restart, lxc);
......
......@@ -27,9 +27,9 @@
#include <seccomp.h>
#include <errno.h>
#include <seccomp.h>
#include "config.h"
#include "lxcseccomp.h"
#include "log.h"
lxc_log_define(lxc_seccomp, lxc);
......
......@@ -23,10 +23,10 @@
#ifndef __lxc_state_h
#define __lxc_state_h
#include "config.h"
#include <lxc/state.h>
#include <sys/param.h>
#include "config.h"
#include "state.h"
#include "namespace.h"
struct lxc_conf;
......
......@@ -32,11 +32,11 @@
#include <sys/stat.h>
#include <sys/file.h>
#include <lxc/lxc.h>
#include <lxc/log.h>
#include <lxc/start.h>
#include <lxc/cgroup.h>
#include <lxc/monitor.h>
#include "lxc.h"
#include "log.h"
#include "start.h"
#include "cgroup.h"
#include "monitor.h"
#include "commands.h"
#include "config.h"
......
......@@ -30,6 +30,7 @@
#include <sys/syscall.h>
#include <sys/types.h>
#include <unistd.h>
#include "config.h"
/* returns 1 on success, 0 if there were any failures */
......
......@@ -25,9 +25,9 @@
#include <Python.h>
#include "structmember.h"
#include <lxc/lxccontainer.h>
#include <lxc/utils.h>
#include <lxc/namespace.h>
#include <lxc/confile.h>
#include "lxc/utils.h"
#include "lxc/namespace.h"
#include "lxc/confile.h"
#include <stdio.h>
#include <sys/wait.h>
......
......@@ -20,8 +20,8 @@
*/
#include <lxc/lxccontainer.h>
#include <lxc/utils.h>
#include <lxc/lsm/lsm.h>
#include "lxc/utils.h"
#include "lxc/lsm/lsm.h"
#include <string.h>
#include <sys/stat.h>
......
......@@ -28,9 +28,9 @@
#include <errno.h>
#include <string.h>
#include <sys/stat.h>
#include "../lxc/cgroup.h"
#include "../lxc/lxc.h"
#include "../lxc/commands.h"
#include "lxc/cgroup.h"
#include "lxc/lxc.h"
#include "lxc/commands.h"
#define MYNAME "lxctest1"
......
......@@ -26,7 +26,7 @@
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include <lxc/state.h>
#include "lxc/state.h"
#define MYNAME "lxctest1"
......
......@@ -26,7 +26,7 @@
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include <lxc/state.h>
#include "lxc/state.h"
#define MYNAME "lxctest1"
......
......@@ -25,7 +25,7 @@
#include <sys/wait.h>
#include <stdlib.h>
#include <errno.h>
#include <lxc/state.h>
#include "lxc/state.h"
#define MYNAME "lxctest1"
......
......@@ -16,7 +16,7 @@
* with this program; if not, write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
#include "../lxc/lxclock.h"
#include "lxc/lxclock.h"
#include <unistd.h>
#include <signal.h>
#include <stdio.h>
......
......@@ -25,7 +25,7 @@
#include <sys/types.h>
#include <sys/wait.h>
#include <lxc/namespace.h>
#include "lxc/namespace.h"
#include <sched.h>
#include <linux/sched.h>
......
......@@ -23,7 +23,7 @@
#include <stdio.h>
#include <string.h>
#include <sys/stat.h>
#include "../lxc/lxc.h"
#include "lxc/lxc.h"
#define MYNAME "snapxxx1"
#define RESTNAME "snapxxx2"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment