diff --git a/indra/llcommon/tests/llsdserialize_test.cpp b/indra/llcommon/tests/llsdserialize_test.cpp
index f2a7530f10f402657e4924e0893bf53035151494..72322c3b727a46b9f24a9527badfa76657eb2229 100644
--- a/indra/llcommon/tests/llsdserialize_test.cpp
+++ b/indra/llcommon/tests/llsdserialize_test.cpp
@@ -274,7 +274,7 @@ class NamedTempFile
         if (0 == GetTempFileNameA(mPath.c_str(), ext.c_str() + pfx_offset, 0, tempname))
         {
             // I always have to look up this call...  :-P
-            LPVOID msgptr;
+            LPSTR msgptr;
             FormatMessageA(
                 FORMAT_MESSAGE_ALLOCATE_BUFFER | 
                 FORMAT_MESSAGE_FROM_SYSTEM |
@@ -282,7 +282,7 @@ class NamedTempFile
                 NULL,
                 GetLastError(),
                 MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
-                LPTSTR(&msgptr),
+                LPSTR(&msgptr),     // have to cast (char**) to (char*)
                 0, NULL );
             LL_ERRS("NamedTempFile") << "GetTempFileName(\"" << mPath << "\", \""
                                      << (ext.c_str() + pfx_offset) << "\") failed: "