Skip to content

Commit

Permalink
Используем функцию PathFileExistsW вместо метода CPath::FileExists.
Browse files Browse the repository at this point in the history
  • Loading branch information
v0lt committed Sep 11, 2024
1 parent 6336328 commit 46c46ce
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/apps/mplayerc/FGManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2734,7 +2734,7 @@ CFGManagerCustom::CFGManagerCustom(LPCWSTR pName, LPUNKNOWN pUnk, HWND hWnd, boo
WORD merit_low = 1;

for (const auto& fo : s.m_ExternalFilters) {
if (fo->fDisabled || (fo->type == FilterOverride::EXTERNAL && !CPath(MakeFullPath(fo->path)).FileExists())) {
if (fo->fDisabled || (fo->type == FilterOverride::EXTERNAL && !::PathFileExistsW(MakeFullPath(fo->path)))) {
continue;
}

Expand Down
4 changes: 2 additions & 2 deletions src/apps/mplayerc/PPageExternalFilters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ BOOL CPPageExternalFilters::OnInitDialog()
if (f->fTemporary) {
name += L" <temporary>";
}
if (!CPath(MakeFullPath(f->path)).FileExists()) {
if (!::PathFileExistsW(MakeFullPath(f->path))) {
name += L" <not found!>";
}
}
Expand Down Expand Up @@ -391,7 +391,7 @@ void CPPageExternalFilters::OnAddRegistered()
CString name = f->name;

if (f->type == FilterOverride::EXTERNAL) {
if (!CPath(MakeFullPath(f->path)).FileExists()) {
if (!::PathFileExistsW(MakeFullPath(f->path))) {
name += L" <not found!>";
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/apps/mplayerc/WebServer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -528,7 +528,7 @@ bool CWebServer::CallCGI(CWebClientSocket* pClient, CStringA& hdr, CStringA& bod

CString cgi;
auto it = m_cgi.find(ext);
if (it == m_cgi.end() || !CPath((*it).second).FileExists()) {
if (it == m_cgi.end() || !::PathFileExistsW((*it).second)) {
return false;
}
cgi = (*it).second;
Expand Down

0 comments on commit 46c46ce

Please sign in to comment.