> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# xcurl_global_suspend

> xcurl_global_suspend

# xcurl\_global\_suspend

终止活动的 Web 请求，并阻止发送新请求。

<a id="syntaxSection" />

## 语法

```cpp theme={null}
void xcurl_global_suspend(
)
```

<a id="parametersSection" />

### 参数

无。

<a id="retvalSection" />

### 返回值

无。

<a id="remarksSection" />

## 备注

<Warning>自 2021 年 4 月的 GDK 起，挂起和恢复现已由 XCurl 在内部自动处理。仍然可以安全地调用此函数，但它已成为空操作。以下备注仅适用于 2021 年 4 月 GDK 之前的 GDK 版本。</Warning>

此函数从简易句柄中止所有 HTTP 请求，并阻止你发送新的 HTTP 请求。

要再次恢复发送 HTTP 请求，请调用函数 [xcurl\_global\_resume](/reference/networking/xcurl/functions/xcurl_global_resume)。

正如 WinHttp 一样，你必须在收到挂起事件时清理网络和 HTTP 句柄。

<a id="requirementsSection" />

## 要求

**头文件：** XCurl.h

**库：** xcurl.lib

**支持的平台：** Windows、XBOX One 系列主机和 XBOX Series 主机

<a id="seealsoSection" />

## 另请参阅

[XCurl 概述](/build/console-features/networking/web-requests/intro-xcurl)\
[HTTP 和 Web 套接字](/build/console-features/networking/web-requests/http-networking)\
[curl](https://curl.se/)\
[xcurl\_global\_resume](/reference/networking/xcurl/functions/xcurl_global_resume)


## Related topics

- [xcurl_global_resume](/zh-CN/reference/networking/xcurl/functions/xcurl_global_resume.md)
- [xcurl_global_init_mem](/zh-CN/reference/networking/xcurl/functions/xcurl_global_init_mem.md)
- [xCurl 概述](/zh-CN/build/console-features/networking/web-requests/intro-xcurl.md)
- [IXtfApplicationClient::Suspend](/zh-CN/reference/tools/xtf/xtfapplication/classes/IXtfApplicationClient/methods/suspend-ixtfapplicationclient-xtfapplication-xbox-windows.md)
- [PlayFabMultiplayerManager.Get().Suspend](/zh-CN/services/playfab/multiplayer/networking/unity-party-api-reference/classes/playfabmultiplayermanager/methods/playfabunitysuspend.md)
