Hi,


I got a trivial error when I compile cryptopp 5.6.2 with my project.

My project uses Unicode build, so OutputDebugString is translated to 
OutputDebugStringW.

This patch will help other people to compile cryptopp source codes with a 
Unicode build project.

 

Thanks,

YoungJin


-- 
-- 
You received this message because you are subscribed to the "Crypto++ Users" 
Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscr...@googlegroups.com.
More information about Crypto++ and this group is available at 
http://www.cryptopp.com.
--- 
You received this message because you are subscribed to the Google Groups 
"Crypto++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cryptopp-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--- a/fipstest.cpp
+++ b/fipstest.cpp
@@ -294,7 +294,7 @@ bool IntegrityCheckModule(const char *moduleFilename, const byte *expectedModule
 	if (!moduleStream)
 	{
 #ifdef CRYPTOPP_WIN32_AVAILABLE
-		OutputDebugString("Crypto++ DLL integrity check failed. Cannot open file for reading.");
+		OutputDebugStringA("Crypto++ DLL integrity check failed. Cannot open file for reading.");
 #endif
 		return false;
 	}
@@ -388,7 +388,7 @@ bool IntegrityCheckModule(const char *moduleFilename, const byte *expectedModule
 	// hash from disk instead
 	if (!VerifyBufsEqual(expectedModuleMac, actualMac, macSize))
 	{
-		OutputDebugString("In memory integrity check failed. This may be caused by debug breakpoints or DLL relocation.\n");
+		OutputDebugStringA("In memory integrity check failed. This may be caused by debug breakpoints or DLL relocation.\n");
 		moduleStream.clear();
 		moduleStream.seekg(0);
 		verifier.Initialize(MakeParameters(Name::OutputBuffer(), ByteArrayParameter(actualMac, (unsigned int)actualMac.size())));
@@ -407,7 +407,7 @@ bool IntegrityCheckModule(const char *moduleFilename, const byte *expectedModule
 #ifdef CRYPTOPP_WIN32_AVAILABLE
 	std::string hexMac;
 	HexEncoder(new StringSink(hexMac)).PutMessageEnd(actualMac, actualMac.size());
-	OutputDebugString((("Crypto++ DLL integrity check failed. Actual MAC is: " + hexMac) + "\n").c_str());
+	OutputDebugStringA((("Crypto++ DLL integrity check failed. Actual MAC is: " + hexMac) + "\n").c_str());
 #endif
 	return false;
 }

Reply via email to