diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2015-05-09 02:43:47 -0400 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2015-05-17 02:17:34 -0400 |
commit | 84443f176e56f9c4140d97c077ea104d5373a666 (patch) | |
tree | 1838501c1bb5e3f8dbd8b7c42aa6113d703adbd3 /src | |
parent | 64c7a36933baa21b3d635e9ee5d48c36541a91f9 (diff) | |
download | rneovim-84443f176e56f9c4140d97c077ea104d5373a666.tar.gz rneovim-84443f176e56f9c4140d97c077ea104d5373a666.tar.bz2 rneovim-84443f176e56f9c4140d97c077ea104d5373a666.zip |
doc: v:servername, serverstart()
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/eval.c | 4 | ||||
-rw-r--r-- | src/nvim/msgpack_rpc/server.c | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c index 906659a1f3..366afb1496 100644 --- a/src/nvim/eval.c +++ b/src/nvim/eval.c @@ -365,7 +365,7 @@ static struct vimvar { } vimvars[VV_LEN] = { /* - * The order here must match the VV_ defines in vim.h! + * The order here must match the VV_ defines in eval.h! * Initializing a union does not work, leave tv.vval empty to get zero's. */ {VV_NAME("count", VAR_NUMBER), VV_COMPAT+VV_RO}, @@ -13356,7 +13356,7 @@ static void f_serverlist(typval_T *argvars, typval_T *rettv) static void f_serverstart(typval_T *argvars, typval_T *rettv) { rettv->v_type = VAR_STRING; - rettv->vval.v_string = NULL; // Will hold the address of the new server. + rettv->vval.v_string = NULL; // Address of the new server if (check_restricted() || check_secure()) { return; diff --git a/src/nvim/msgpack_rpc/server.c b/src/nvim/msgpack_rpc/server.c index 884a2f8bff..ab1b04d73f 100644 --- a/src/nvim/msgpack_rpc/server.c +++ b/src/nvim/msgpack_rpc/server.c @@ -28,13 +28,13 @@ typedef enum { } ServerType; typedef struct { - // The address of a pipe, or string value of a tcp address. + // Pipe/socket path, or TCP address string char addr[ADDRESS_MAX_SIZE]; // Type of the union below ServerType type; - // This is either a tcp server or unix socket(named pipe on windows) + // TCP server or unix socket (named pipe on Windows) union { struct { uv_tcp_t handle; @@ -144,7 +144,7 @@ int server_start(const char *endpoint) size_t addr_len = (size_t)(ip_end - addr); if (addr_len > sizeof(ip) - 1) { - // Maximum length of an IP address buffer is 15(eg: 255.255.255.255) + // Maximum length of an IPv4 address buffer is 15 (eg: 255.255.255.255) addr_len = sizeof(ip) - 1; } @@ -245,7 +245,7 @@ void server_stop(char *endpoint) // Trim to `ADDRESS_MAX_SIZE` xstrlcpy(addr, endpoint, sizeof(addr)); - int i = 0; // The index of the server whose address equals addr. + int i = 0; // Index of the server whose address equals addr. for (; i < servers.ga_len; i++) { server = ((Server **)servers.ga_data)[i]; if (strcmp(addr, server->addr) == 0) { |