/* Read 512 bytes */
if (!ReadFile(DbHandle,
Buffer->LineBuffer,
- 512,
+ sizeof(Buffer->LineBuffer) - 1,
&Read,
NULL)) return NULL;
/* Find out where the line ends */
p1 = Buffer->LineBuffer;
+ Buffer->LineBuffer[Read] = ANSI_NULL;
p = strchr(Buffer->LineBuffer, '\n');
/* Bail out if the file is parsed */
PWSTHREAD Thread;
INT ErrorCode;
PPROTOENT Protoent;
- PVOID GetProtoBuffer;
+ PVOID GetProtoBuffer;
HANDLE DbHandle;
DPRINT("getprotobynumber: %lx\n", number);
PWSTHREAD Thread;
INT ErrorCode;
PPROTOENT Protoent;
- PVOID GetProtoBuffer;
+ PVOID GetProtoBuffer;
HANDLE DbHandle;
DPRINT("getprotobyname: %s\n", name);