easyloggingpp
easyloggingpp copied to clipboard
Fix a warning: 'ex' unreferenced local variable
This is a
- [x] Bugfix
I have
- [x] Run the tests
After I updated easylogging from v9.96.7 to v9.97.0, this code: catch(std::exception & ex){ // Extremely low memory situation; don't let exception be unhandled. } will generate a warning: warning C4101: 'ex': unreferenced local variable and our build will fail.
I would also like this Pull Request included in the next version of Easylogging++.
I have the same problem compiling with Visual Studio 2019 and this Pull Request solves the problem.
A simple test program using the master version of Easylogging++ demonstrates the problem:
C:\Git_Repos\easyloggingpp\src>cl /EHsc /W4 test783.cpp easylogging++.cc
Microsoft (R) C/C++ Optimizing Compiler Version 19.27.29112 for x86
Copyright (C) Microsoft Corporation. All rights reserved.
test783.cpp
easylogging++.cc
easylogging++.cc(2657): warning C4101: 'ex': unreferenced local variable
Generating Code...
Microsoft (R) Incremental Linker Version 14.27.29112.0
Copyright (C) Microsoft Corporation. All rights reserved.
/out:test783.exe
test783.obj
easylogging++.obj
@yanchoyanev are you able to merge this Pull Request to master?
Hi please merge this to master