From: Bram Moolenaar Date: Thu, 31 Jan 2019 10:00:42 +0000 (+0100) Subject: patch 8.1.0855: cannot build xxd with MSVC 10 X-Git-Tag: v8.1.0855 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=af703585a34aa30bb5bdf8c05e4be8b3c66f787a;p=vim patch 8.1.0855: cannot build xxd with MSVC 10 Problem: Cannot build xxd with MSVC 10. Solution: Move declaration to start of block. --- diff --git a/src/version.c b/src/version.c index c1196431b..4080d5ece 100644 --- a/src/version.c +++ b/src/version.c @@ -783,6 +783,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 855, /**/ 854, /**/ diff --git a/src/xxd/xxd.c b/src/xxd/xxd.c index b8761fc29..c24089e4e 100644 --- a/src/xxd/xxd.c +++ b/src/xxd/xxd.c @@ -472,6 +472,7 @@ main(int argc, char *argv[]) unsigned long displayoff = 0; static char l[LLEN+1]; /* static because it may be too big for stack */ char *pp; + int addrlen = 9; #ifdef AMIGA /* This program doesn't work when started from the Workbench */ @@ -820,7 +821,6 @@ main(int argc, char *argv[]) else /* hextype == HEX_BITS */ grplen = 8 * octspergrp + 1; - int addrlen = 9; e = 0; while ((length < 0 || n < length) && (e = getc(fp)) != EOF) {