PVS: V530 The return value of function 'freopen' is required to be utilized
This commit is contained in:
@@ -78,10 +78,13 @@ public:
|
||||
: fi(Base::FileInfo::getTempFileName()), file(f)
|
||||
{
|
||||
#ifdef WIN32
|
||||
_wfreopen(fi.toStdWString().c_str(),L"w",file);
|
||||
FILE* ptr = _wfreopen(fi.toStdWString().c_str(),L"w",file);
|
||||
#else
|
||||
freopen(fi.filePath().c_str(),"w",file);
|
||||
FILE* ptr = freopen(fi.filePath().c_str(),"w",file);
|
||||
#endif
|
||||
if (!ptr) {
|
||||
std::cerr << "Failed to reopen file" << std::endl;
|
||||
}
|
||||
}
|
||||
~Redirection()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user