From 5eeeac319e5215cef0e686872e3eb3dcd0dceb87 Mon Sep 17 00:00:00 2001 From: Olorunfemi-Ojo Tomiwa Date: Tue, 11 Oct 2022 10:24:18 +0100 Subject: [PATCH] added docs to scanner.c --- src/scanner.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/scanner.c b/src/scanner.c index 9fc1c40..73e7a77 100644 --- a/src/scanner.c +++ b/src/scanner.c @@ -124,6 +124,7 @@ int scanBytes(LPCTSTR path, LPCWSTR name, int debug) initialize(debug); openSession(debug); + // Read bytes from file and the bytes size HANDLE hFile = CreateFileA(path, GENERIC_READ, 0, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL); DWORD dwFileSize = GetFileSize(hFile, NULL); BYTE* buffer = (BYTE*) VirtualAlloc(NULL, dwFileSize, MEM_COMMIT, PAGE_READWRITE);