From eec4866e1cfaa6d568aa2d089b3329309e285483 Mon Sep 17 00:00:00 2001 From: ericm Date: Mon, 13 Jun 2005 17:45:26 +0000 Subject: [PATCH] some minor changes in lsd upcall. --- lustre/utils/lsd_upcall.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/lustre/utils/lsd_upcall.c b/lustre/utils/lsd_upcall.c index a1fc338..9e1f640 100644 --- a/lustre/utils/lsd_upcall.c +++ b/lustre/utils/lsd_upcall.c @@ -282,6 +282,16 @@ int parse_perm(__u32 *perm, char *str) return 0; } +int parse_nid(ptl_nid_t *nidp, char *nid_str) +{ + if (!strcmp(nid_str, "*")) { + *nidp = PTL_NID_ANY; + return 0; + } + + return ptl_parse_nid(nidp, nid_str); +} + int get_one_perm(FILE *fp, struct lsd_permission *perm) { char nid_str[256], perm_str[256]; @@ -298,7 +308,7 @@ again: if (rc != 2) return -1; - if (ptl_parse_nid(&perm->nid, nid_str)) + if (parse_nid(&perm->nid, nid_str)) return -1; if (parse_perm(&perm->perm, perm_str)) -- 1.8.3.1