瀏覽代碼

Using client parameter in function CtConnect

Using the global client variable might lead to strange behavoir if multiple clients are allocated and to crashes in the case the client was not initialized with CtStartClient()
Michael Clausen 9 年之前
父節點
當前提交
462840cf6e
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/Cedar/Client.c

+ 1 - 1
src/Cedar/Client.c

@@ -6661,7 +6661,7 @@ bool CtConnect(CLIENT *c, RPC_CLIENT_CONNECT *connect)
 				CiSetError(c, ERR_ACCOUNT_ACTIVE);
 			}
 			else if (r->ClientAuth->AuthType == CLIENT_AUTHTYPE_SECURE &&
-				client->UseSecureDeviceId == 0)
+				c->UseSecureDeviceId == 0)
 			{
 				// Secure device is not specified
 				CiSetError(c, ERR_NO_SECURE_DEVICE_SPECIFIED);