netns: Trivial code reorganization.

This commit is contained in:
Tom Goff 2016-02-19 17:37:20 -05:00
parent d4d2f36481
commit d42d54a477

View file

@ -22,6 +22,23 @@
/* #define DEBUG */ /* #define DEBUG */
typedef struct vcmdentry {
PyObject_HEAD
vnode_client_t *_client;
int _client_connected;
} VCmd;
typedef struct {
PyObject_HEAD
int32_t _cmdid;
int _complete;
int _status;
pthread_mutex_t _mutex;
pthread_cond_t _cv;
} VCmdWait;
int verbose; int verbose;
/* ev_default_loop(0) is not used because it interferes with SIGCHLD */ /* ev_default_loop(0) is not used because it interferes with SIGCHLD */
@ -180,15 +197,6 @@ static int init_evloop(void)
return 0; return 0;
} }
typedef struct {
PyObject_HEAD
int32_t _cmdid;
int _complete;
int _status;
pthread_mutex_t _mutex;
pthread_cond_t _cv;
} VCmdWait;
static PyObject *VCmdWait_new(PyTypeObject *type, static PyObject *VCmdWait_new(PyTypeObject *type,
PyObject *args, PyObject *kwds) PyObject *args, PyObject *kwds)
@ -309,13 +317,6 @@ static PyTypeObject vcmd_VCmdWaitType = {
}; };
typedef struct vcmdentry {
PyObject_HEAD
vnode_client_t *_client;
int _client_connected;
} VCmd;
static PyObject *VCmd_new(PyTypeObject *type, PyObject *args, PyObject *kwds) static PyObject *VCmd_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
{ {
VCmd *self; VCmd *self;