nfsd: properly handle embedded newlines in fault_injection input
authorJeff Layton <jlayton@primarydata.com>
Wed, 18 Jun 2014 19:00:19 +0000 (15:00 -0400)
committerJ. Bruce Fields <bfields@redhat.com>
Mon, 23 Jun 2014 15:31:38 +0000 (11:31 -0400)
commitd4c8e34fe8beeb7877ce7f8d2da6affd7231b2cb
tree4e493b1102bfedbfec2fc2a9e3258010e3d066a5
parentf7ce5d284253db9760fc1c3a96b66ec2d9abf0ab
nfsd: properly handle embedded newlines in fault_injection input

Currently rpc_pton() fails to handle the case where you echo an address
into the file, as it barfs on the newline. Ensure that we NULL out the
first occurrence of any newline.

Signed-off-by: Jeff Layton <jlayton@primarydata.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
fs/nfsd/fault_inject.c