Skip to content

Commit

Permalink
macro: move LXC_CMD_DATA_MAX from commands.h
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
  • Loading branch information
Christian Brauner committed Sep 30, 2018
1 parent c05ad00 commit ceecb90
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/lxc/commands.h
Expand Up @@ -25,17 +25,15 @@
#define __LXC_COMMANDS_H

#include <stdio.h>
#include <unistd.h>
#include <sys/types.h>
#include <unistd.h>

#include "state.h"
#include "lxccontainer.h"

#define LXC_CMD_DATA_MAX (MAXPATHLEN * 2)

/* https://developer.gnome.org/glib/2.28/glib-Type-Conversion-Macros.html */
#define INT_TO_PTR(n) ((void *)(long)(n))
#define PTR_TO_INT(p) ((int)(long)(p))
#include "macro.h"
#include "state.h"

typedef enum {
LXC_CMD_CONSOLE,
Expand Down
1 change: 1 addition & 0 deletions src/lxc/macro.h
Expand Up @@ -122,6 +122,7 @@
#define LXC_PROC_PID_FD_LEN (6 + LXC_NUMSTRLEN64 + 4 + LXC_NUMSTRLEN64 + 1)
/* /proc/pid-to-str/status\0 = (5 + 21 + 7 + 1) */
#define LXC_PROC_STATUS_LEN (5 + (LXC_NUMSTRLEN64) + 7 + 1)
#define LXC_CMD_DATA_MAX (MAXPATHLEN * 2)

/* loop devices */
#ifndef LO_FLAGS_AUTOCLEAR
Expand Down

0 comments on commit ceecb90

Please sign in to comment.