>The opening process can duplicate the handle as many times as required, but after it is opened, the named pipe instance cannot be opened by another client.
死んでしまえ!
std::pair<bool, unsigned long long int> GetHash(const wchar_t *str){
typedef std::pair<bool, unsigned long long int> rettype;
std::size_t len = std::wcslen(str);
unsigned long long int v = 0x0123456789ABCDEFLL;
for(std::size_t i = 0; i < len; ++i){
v = v * 137 + str[i] * 581;
}
return rettype(true, v);
}
std::pair<bool, unsigned long long int> GetHash(const char *str){
typedef std::pair<bool, unsigned long long int> rettype;
>If hNamedPipe was not opened with FILE_FLAG_OVERLAPPED, the function does not return until a client is connected or an error occurs. Successful synchronous operations result in the function returning a nonzero value if a client connects after the function is called.
えー。