diff options
author | Alex Elder <elder@linaro.org> | 2015-04-17 14:41:47 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@google.com> | 2015-05-01 16:41:11 +0200 |
commit | 22fd2a8ade59bb97f0a64282ba5b3903ba3e9e89 (patch) | |
tree | a6188c48e82f0098c03812f430a321d019e0fa02 /drivers/staging/greybus/manifest.c | |
parent | 55b930cd17a7cd66a1fb2a587660a344ea5a9ee2 (diff) | |
download | linux-22fd2a8ade59bb97f0a64282ba5b3903ba3e9e89.tar.bz2 |
greybus: bundle: use kstrdup() for state file
The kernfs code guarantees we'll get a NUL-terminated buffer.
Use kstrdup() rather than kzalloc() + memcpy() in state_store()
making it slightly clearer what we're doing. This has the added
benefit of guaranteeing that the stored string has no NUL character
inside it.
Signed-off-by: Alex Elder <elder@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers/staging/greybus/manifest.c')
0 files changed, 0 insertions, 0 deletions