01-12-2022 01:09 PM
Is it not possible to return custom values from a thread pool function?
I'm using CmtGetThreadPoolFunctionAttribute to get the thread pool function return value, but it seems to only send me 0 (pass) and -1 (fail). My thread function though can return several custom integer value codes depending on what exactly failed.
Is there a way?
01-12-2022 01:24 PM
Argh. Disregard. This isn't true. I had a bug in my test code. The thread pool function will indeed return any value you want it to into the ATTR_TP_FUNCTION_RETURN_VALUE attribute. That's super helpful for parsing failure codes!