Commit b4cdbb8c authored by David Rich's avatar David Rich Committed by Rob Latham
Browse files

Some cleanup.

parent 8b868619
......@@ -75,6 +75,7 @@ int kv_open(kv_context *context, char * server, char *name,
ret = HG_Get_output(handle, &open_out);
assert(ret == HG_SUCCESS);
ret = open_out.ret;
assert(ret == HG_SUCCESS);
/* set up the other calls here: idea is we'll pay the registration cost
* once here but can reuse the handles and identifiers multiple times*/
......@@ -571,7 +571,7 @@ kv_context *kv_server_register(margo_instance_id mid);
ret = margo_addr_self(context->mid, &addr_self);
if(ret != HG_SUCCESS)
fprintf(stderr, "Error: mago_addr_selff()\n");
fprintf(stderr, "Error: margo_addr_selff()\n");
......@@ -65,7 +65,7 @@ int main(int argc, char *argv[])
hret = HG_Addr_to_string(hgcl, server_addr_str, &server_addr_str_sz, server_addr);
DIE_IF(hret != HG_SUCCESS, "HG_Addr_to_string");
HG_Addr_free(hgcl, server_addr);
printf("server (rank %d): server add_str: %s\n", rank, server_addr_str);
printf("server (rank %d): server addr_str: %s\n", rank, server_addr_str);
// broadcast (send) server address to all clients
MPI_Bcast(server_addr_str, 128, MPI_BYTE, 0, MPI_COMM_WORLD);
......@@ -81,11 +81,11 @@ int main(int argc, char *argv[])
MPI_Comm_split(MPI_COMM_WORLD, 1, rank, &clientComm);
// broadcast (recv) server address
MPI_Bcast(server_addr_str, 128, MPI_BYTE, 0, MPI_COMM_WORLD);
printf("client (rank %d): server add_str: %s\n", rank, server_addr_str);
printf("client (rank %d): server addr_str: %s\n", rank, server_addr_str);
// kv-client
sprintf(client_addr_str, "cci+tcp://localhost:534%02d", rank);
printf("client (rank %d): client add_str: %s\n", rank, client_addr_str);
printf("client (rank %d): client addr_str: %s\n", rank, client_addr_str);
kv_context *context = kv_client_register(client_addr_str);
// open specified "DB" (pass in the server's address)
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