From 97e379083dbd56cf5d1b2525c1905df9110e2621 Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Mon, 26 May 2014 10:29:01 +0100 Subject: Scope reduce a variable. --- riscos/filetype.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'riscos') diff --git a/riscos/filetype.c b/riscos/filetype.c index 86aafa85a..d71c500c0 100644 --- a/riscos/filetype.c +++ b/riscos/filetype.c @@ -72,7 +72,7 @@ const char *fetch_filetype(const char *unix_path) struct type_entry *t; unsigned int len = strlen(unix_path) + 100; char *path = calloc(len, 1); - char *r, *slash; + char *r; os_error *error; bits file_type, temp; int objtype; @@ -110,7 +110,7 @@ const char *fetch_filetype(const char *unix_path) /* If filetype is text or data, and the file has an extension, try to * map the extension to a filetype via the MimeMap file. */ if (file_type == osfile_TYPE_TEXT || file_type == osfile_TYPE_DATA) { - slash = strrchr(path, '/'); + char *slash = strrchr(path, '/'); if (slash) { error = xmimemaptranslate_extension_to_filetype( slash+1, &temp); -- cgit v1.2.3