Skip to content

Commit c3f64f5

Browse files
committed
implement PathCchCanonicalizeEx, PathCchRemoveFileSpec
- implement PathCchCanonicalizeEx as call to PathCanonicalize - implement PathCchRemoveFileSpec as a call to PathRemoveFileSpec
1 parent aed0c2c commit c3f64f5

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

api-ms-win-core-path-HACK.cpp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,20 @@
22
//
33

44
#include "stdafx.h"
5+
#include <Shlwapi.h>
6+
#pragma comment(lib, "Shlwapi.lib")
7+
8+
9+
HRESULT PathCchCanonicalizeEx(PWSTR pszPathOut, size_t cchPathOut, PCWSTR pszPathIn, unsigned long dwFlags)
10+
{
11+
auto ret = PathCanonicalize(pszPathOut, pszPathIn);
12+
return ret ? S_OK : E_FAIL;
13+
}
14+
15+
HRESULT PathCchRemoveFileSpec(PWSTR pszPath, size_t cchPath)
16+
{
17+
auto ret = PathRemoveFileSpec(pszPath);
18+
return ret ? S_OK : E_FAIL;
19+
}
520

621

0 commit comments

Comments
 (0)