From 17f8e1585933c3c47c66f6465fd3fd53ae162813 Mon Sep 17 00:00:00 2001 From: eeb Date: Thu, 7 Jul 2005 10:04:03 +0000 Subject: [PATCH] * socknal working again --- lnet/klnds/socklnd/socklnd_cb.c | 2 +- lnet/libcfs/nidstrings.c | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/lnet/klnds/socklnd/socklnd_cb.c b/lnet/klnds/socklnd/socklnd_cb.c index 2d12fe4..797fd3c 100644 --- a/lnet/klnds/socklnd/socklnd_cb.c +++ b/lnet/klnds/socklnd/socklnd_cb.c @@ -1866,7 +1866,7 @@ ksocknal_recv_hello (ptl_ni_t *ni, ksock_conn_t *conn, if (!active) { /* don't know peer's nid yet */ *peerid = recv_id; } else if (peerid->pid != recv_id.pid || - peerid->pid != recv_id.nid) { + peerid->nid != recv_id.nid) { LCONSOLE_ERROR("Connected successfully to %s on host " "%u.%u.%u.%u, but they claimed they were " "%s; please check your Lustre " diff --git a/lnet/libcfs/nidstrings.c b/lnet/libcfs/nidstrings.c index b0ed502..f3005d4 100644 --- a/lnet/libcfs/nidstrings.c +++ b/lnet/libcfs/nidstrings.c @@ -499,10 +499,9 @@ libcfs_str2nid(char *str) char * libcfs_id2str(ptl_process_id_t id) { - char *str = libcfs_nid2str(id.nid); - int len = strlen(str); - - snprintf(str + len, PTL_NIDSTR_SIZE - len, "-%u", id.pid); + char *str = libcfs_next_nidstring(); + + snprintf(str, PTL_NIDSTR_SIZE, "%u-%s", id.pid, libcfs_nid2str(id.nid)); return str; } -- 1.8.3.1