aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2013-09-11 00:41:34 -0400
committerKent Overstreet <kmo@daterainc.com>2013-11-11 00:56:43 -0500
commitc86949486d41d9e7d7681fc72923555114fd702f (patch)
tree54656066a419dc4f6802acc256abc2816346ec43
parent5ceaaad7047745c1c02150c39d3fb623b7948d48 (diff)
bcache: defensively handle format strings
Just to be safe, call the error reporting function with "%s" to avoid any possible future format string leak. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Kent Overstreet <kmo@daterainc.com>
-rw-r--r--drivers/md/bcache/super.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c
index 70708ab0b8f9..dec15cd2d797 100644
--- a/drivers/md/bcache/super.c
+++ b/drivers/md/bcache/super.c
@@ -1670,7 +1670,7 @@ static void run_cache_set(struct cache_set *c)
1670err: 1670err:
1671 closure_sync(&cl); 1671 closure_sync(&cl);
1672 /* XXX: test this, it's broken */ 1672 /* XXX: test this, it's broken */
1673 bch_cache_set_error(c, err); 1673 bch_cache_set_error(c, "%s", err);
1674} 1674}
1675 1675
1676static bool can_attach_cache(struct cache *ca, struct cache_set *c) 1676static bool can_attach_cache(struct cache *ca, struct cache_set *c)