summaryrefslogtreecommitdiffstats
path: root/fs/fat/inode.c
diff options
context:
space:
mode:
authorManuel Schölling <manuel.schoelling@gmx.de>2014-06-06 23:36:38 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2014-06-07 01:08:11 +0200
commitef19470ef87d06ed906e2fbb6c9aeb7aaa9acc56 (patch)
treedfc734082af8331d2ab8a4c05e96c250ebc87c07 /fs/fat/inode.c
parentfs/fat/: add support for DOS 1.x formatted volumes (diff)
downloadlinux-ef19470ef87d06ed906e2fbb6c9aeb7aaa9acc56.tar.xz
linux-ef19470ef87d06ed906e2fbb6c9aeb7aaa9acc56.zip
fs/fat/inode.c: clean up string initializations (char[] instead of char *)
Initializations like 'char *foo = "bar"' will create two variables: a static string and a pointer (foo) to that static string. Instead 'char foo[] = "bar"' will declare a single variable and will end up in shorter assembly (according to Jeff Garzik on the KernelJanitor's TODO list). Signed-off-by: Manuel Schölling <manuel.schoelling@gmx.de> Acked-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/fat/inode.c')
-rw-r--r--fs/fat/inode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/fat/inode.c b/fs/fat/inode.c
index babff0f40696..9c83594d7fb5 100644
--- a/fs/fat/inode.c
+++ b/fs/fat/inode.c
@@ -421,7 +421,7 @@ struct inode *fat_iget(struct super_block *sb, loff_t i_pos)
static int is_exec(unsigned char *extension)
{
- unsigned char *exe_extensions = "EXECOMBAT", *walk;
+ unsigned char exe_extensions[] = "EXECOMBAT", *walk;
for (walk = exe_extensions; *walk; walk += 3)
if (!strncmp(extension, walk, 3))