summaryrefslogtreecommitdiff
path: root/utils/filename.c
diff options
context:
space:
mode:
authorFran├žois Revel <mmu_man@netsurf-browser.org>2008-07-29 09:34:43 +0000
committerFran├žois Revel <mmu_man@netsurf-browser.org>2008-07-29 09:34:43 +0000
commit4c6006e6f4d50ed9fadcd21a83afc177fd3f99be (patch)
tree74a5994cc156e41a72d31c20526f5992258ff953 /utils/filename.c
parent34e0f4db3fa7994614e37be9973a7e1ef593b0be (diff)
downloadnetsurf-4c6006e6f4d50ed9fadcd21a83afc177fd3f99be.tar.gz
netsurf-4c6006e6f4d50ed9fadcd21a83afc177fd3f99be.tar.bz2
C89
svn path=/trunk/netsurf/; revision=4795
Diffstat (limited to 'utils/filename.c')
-rw-r--r--utils/filename.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/utils/filename.c b/utils/filename.c
index 525c95287..55a0aea6a 100644
--- a/utils/filename.c
+++ b/utils/filename.c
@@ -362,6 +362,7 @@ static struct directory *filename_create_directory(const char *prefix) {
int index;
struct directory *old_dir, *new_dir, *prev_dir = NULL;
char dir_prefix[16];
+ int i;
/* get the lowest unique prefix, or use the provided one */
if (!prefix) {
@@ -433,7 +434,7 @@ static struct directory *filename_create_directory(const char *prefix) {
TEMP_FILENAME_PREFIX);
last_1 = filename_directory + strlen(TEMP_FILENAME_PREFIX) + 1;
last_2 = new_dir->prefix;
- for (int i = 0; i < 3 && *last_2; i++) {
+ for (i = 0; i < 3 && *last_2; i++) {
*last_1++ = *last_2++;
while (*last_2 && *last_2 != '/')
*last_1++ = *last_2++;