提交 ef7ffe8f 编写于 作者: A Alex Riesen 提交者: Linus Torvalds

sunrpc: use formatting of module name in SUNRPC

gcc-4.3.3 produces the warning:
  "format not a string literal and no format arguments"
Signed-off-by: NAlex Riesen <raa.lkml@gmail.com>
Cc: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: Chuck Lever <cel@citi.umich.edu>
Cc: David S. Miller <davem@davemloft.net>
Acked-by: NTom Talpey <tmtalpey@gmail.com>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 08a82c68
...@@ -166,7 +166,6 @@ EXPORT_SYMBOL_GPL(xprt_unregister_transport); ...@@ -166,7 +166,6 @@ EXPORT_SYMBOL_GPL(xprt_unregister_transport);
int xprt_load_transport(const char *transport_name) int xprt_load_transport(const char *transport_name)
{ {
struct xprt_class *t; struct xprt_class *t;
char module_name[sizeof t->name + 5];
int result; int result;
result = 0; result = 0;
...@@ -178,9 +177,7 @@ int xprt_load_transport(const char *transport_name) ...@@ -178,9 +177,7 @@ int xprt_load_transport(const char *transport_name)
} }
} }
spin_unlock(&xprt_list_lock); spin_unlock(&xprt_list_lock);
strcpy(module_name, "xprt"); result = request_module("xprt%s", transport_name);
strncat(module_name, transport_name, sizeof t->name);
result = request_module(module_name);
out: out:
return result; return result;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册