On Mon Sep 29 11:01:07 2025 +0000, Rémi Bernon wrote:
Is it supposed to be allowed to fail? Shouldn't the error case be handled in PSGetNameFromPropertyKey with a FIXME instead?
Yes, `PSGetNameFromPropertyKey` returns `TYPE_E_ELEMENTNOTFOUND` for unknown keys, so using the custom property syntax is something the caller needs to do:
```c PROPERTYKEY key = { 0 }; WCHAR* name; HRESULT hr;
key.pid = 0xdeadbeef; hr = PSGetNameFromPropertyKey( key, &name ); printf( "hr: %#lx\n", hr ); ```
That being said, we probably should log a FIXME in `PSGetNameFromPropertyKey` before returning TYPE_E_ELEMENTNOTFOUND.