summaryrefslogtreecommitdiffstats
path: root/Source/cmCallVisualStudioMacro.cxx
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2014-11-13 18:27:56 (GMT)
committerBen Boeckel <ben.boeckel@kitware.com>2014-11-13 18:27:56 (GMT)
commit8d379cd7ac25481ef3b43da12aade24b1e47ccdf (patch)
tree723095682ff9c55941993a0616f66f8d56449bad /Source/cmCallVisualStudioMacro.cxx
parentdd563e1eb3002578fcc28f9cc4ef9d2326043a23 (diff)
downloadCMake-8d379cd7ac25481ef3b43da12aade24b1e47ccdf.zip
CMake-8d379cd7ac25481ef3b43da12aade24b1e47ccdf.tar.gz
CMake-8d379cd7ac25481ef3b43da12aade24b1e47ccdf.tar.bz2
cmCallVisualStudioMacro: fix a shadowing warning
Diffstat (limited to 'Source/cmCallVisualStudioMacro.cxx')
-rw-r--r--Source/cmCallVisualStudioMacro.cxx13
1 files changed, 7 insertions, 6 deletions
diff --git a/Source/cmCallVisualStudioMacro.cxx b/Source/cmCallVisualStudioMacro.cxx
index 0c15477..8f22f80 100644
--- a/Source/cmCallVisualStudioMacro.cxx
+++ b/Source/cmCallVisualStudioMacro.cxx
@@ -63,12 +63,13 @@ static bool LogErrorsAsMessages;
{ \
if (LogErrorsAsMessages) \
{ \
- std::ostringstream oss; \
- oss.flags(std::ios::hex); \
- oss << context << " failed HRESULT, hr = 0x" << hr << std::endl; \
- oss.flags(std::ios::dec); \
- oss << __FILE__ << "(" << __LINE__ << ")"; \
- cmSystemTools::Message(oss.str().c_str()); \
+ std::ostringstream _hresult_oss; \
+ _hresult_oss.flags(std::ios::hex); \
+ _hresult_oss << context << " failed HRESULT, hr = 0x" \
+ << hr << std::endl; \
+ _hresult_oss.flags(std::ios::dec); \
+ _hresult_oss << __FILE__ << "(" << __LINE__ << ")"; \
+ cmSystemTools::Message(_hresult_oss.str().c_str()); \
} \
}