From a186b0d65c00a338995ad1f6379ef232742ab224 Mon Sep 17 00:00:00 2001 From: Jeffrey Altman Date: Wed, 19 Sep 2007 22:27:53 +0000 Subject: [PATCH] windows-hex-dump-20070919 remove the broken percent quoting from OutputDebugHexDump as it is not required. We never use the resulting string as a print format string. --- src/WINNT/afsd/smb3.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/WINNT/afsd/smb3.c b/src/WINNT/afsd/smb3.c index f2005fc16..078ed5dc2 100644 --- a/src/WINNT/afsd/smb3.c +++ b/src/WINNT/afsd/smb3.c @@ -156,7 +156,7 @@ void OutputDebugF(char * format, ...) { } void OutputDebugHexDump(unsigned char * buffer, int len) { - int i,j,k,pcts=0; + int i,j,k; char buf[256]; static char tr[16] = {'0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F'}; @@ -181,13 +181,9 @@ void OutputDebugHexDump(unsigned char * buffer, int len) { buf[j] = tr[k / 16]; buf[j+1] = tr[k % 16]; j = (i%16); - j = j + 56 + ((j>7)?1:0) + pcts; + j = j + 56 + ((j>7)?1:0); buf[j] = (k>32 && k<127)?k:'.'; - if (k == '%') { - buf[++j] = k; - pcts++; - } } if(i) { osi_Log0(smb_logp, osi_LogSaveString(smb_logp, buf)); -- 2.39.5