Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
LU-9325 mdt: replace simple_strtol() with kstrtol()
[fs/lustre-release.git]
/
lustre
/
mdt
/
mdt_handler.c
diff --git
a/lustre/mdt/mdt_handler.c
b/lustre/mdt/mdt_handler.c
index
82fc529
..
be9797b
100644
(file)
--- a/
lustre/mdt/mdt_handler.c
+++ b/
lustre/mdt/mdt_handler.c
@@
-5599,7
+5599,10
@@
static int mdt_init0(const struct lu_env *env, struct mdt_device *m,
LASSERT(lsi->lsi_lmd);
/* CMD is supported only in IAM mode */
LASSERT(num);
LASSERT(lsi->lsi_lmd);
/* CMD is supported only in IAM mode */
LASSERT(num);
- node_id = simple_strtol(num, NULL, 10);
+ rc = kstrtol(num, 10, &node_id);
+ if (rc)
+ RETURN(rc);
+
obd->u.obt.obt_magic = OBT_MAGIC;
if (lsi->lsi_lmd->lmd_flags & LMD_FLG_SKIP_LFSCK)
m->mdt_skip_lfsck = 1;
obd->u.obt.obt_magic = OBT_MAGIC;
if (lsi->lsi_lmd->lmd_flags & LMD_FLG_SKIP_LFSCK)
m->mdt_skip_lfsck = 1;