| 82 | } |
| 83 | |
| 84 | HRESULT GetItemAttributes(const TCHAR *szItemParsingPath, SFGAOF *pItemAttributes) |
| 85 | { |
| 86 | if (szItemParsingPath == NULL || pItemAttributes == NULL) |
| 87 | { |
| 88 | return E_FAIL; |
| 89 | } |
| 90 | |
| 91 | unique_pidl_absolute pidl; |
| 92 | HRESULT hr = SHParseDisplayName(szItemParsingPath, nullptr, wil::out_param(pidl), 0, nullptr); |
| 93 | |
| 94 | if (SUCCEEDED(hr)) |
| 95 | { |
| 96 | hr = GetItemAttributes(pidl.get(), pItemAttributes); |
| 97 | } |
| 98 | |
| 99 | return hr; |
| 100 | } |
| 101 | |
| 102 | HRESULT GetItemAttributes(PCIDLIST_ABSOLUTE pidl, SFGAOF *pItemAttributes) |
| 103 | { |