hsem (HSEM) - input
pnpss (PPIPESEMSTATE) - output
cbBuf (ULONG) - input
ulrc (APIRET) - returns
DosQueryNPipeSemState returns one of the following values: