From: Jeffrey Altman Date: Wed, 19 Sep 2007 22:29:29 +0000 (+0000) Subject: DEVEL15-windows-hex-dump-20070919 X-Git-Tag: openafs-devel-1_5_25~6 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=17038da92f9a6ee789f7ee160b7277bc05b69ac8;p=packages%2Fo%2Fopenafs.git DEVEL15-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. (cherry picked from commit a186b0d65c00a338995ad1f6379ef232742ab224) --- diff --git a/src/WINNT/afsd/smb3.c b/src/WINNT/afsd/smb3.c index 0cdd50394..a6fa12415 100644 --- a/src/WINNT/afsd/smb3.c +++ b/src/WINNT/afsd/smb3.c @@ -158,7 +158,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'}; @@ -183,13 +183,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));