Fixed CreateHexDump() filling the string with garbage
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1357 0a769ca7-a7f5-676a-18bf-c427514a06d6
This commit is contained in:
parent
f9479f66aa
commit
fbacc1e1c4
@ -538,6 +538,7 @@ AString & CreateHexDump(AString & a_Out, const void * a_Data, int a_Size, int a_
|
|||||||
unsigned char c = ((unsigned char *)a_Data)[i + j];
|
unsigned char c = ((unsigned char *)a_Data)[i + j];
|
||||||
p[0] = HEX(c >> 4);
|
p[0] = HEX(c >> 4);
|
||||||
p[1] = HEX(c & 0xf);
|
p[1] = HEX(c & 0xf);
|
||||||
|
p[2] = ' ';
|
||||||
if (c >= ' ')
|
if (c >= ' ')
|
||||||
{
|
{
|
||||||
q[0] = (char)c;
|
q[0] = (char)c;
|
||||||
|
Loading…
Reference in New Issue
Block a user