> ## 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_init_mem

> xcurl_global_init_mem

# xcurl\_global\_init\_mem

Initialise XCurl avec des allocateurs de mémoire personnalisés.

<a id="syntaxSection" />

## Syntaxe

```cpp theme={null}
CURL_EXTERN CURLcode xcurl_global_init_mem(long flags,
    xcurl_alloc_memory_callback m,
    xcurl_free_memory_callback f,
    xcurl_realloc_memory_callback r,
    curl_strdup_callback s,
    xcurl_calloc_memory_callback c
)
```

<a id="parametersSection" />

### Paramètres

*flags*   \_In\_\
Type : long

Ce paramètre est ignoré par XCurl.

*m*   \_In\_\
Type : xcurl\_alloc\_memory\_callback\*

Remplacement de malloc()

*f*   \_In\_\
Type : xcurl\_free\_memory\_callback\*

Remplacement de free()

*r*   \_In\_\
Type : xcurl\_realloc\_memory\_callback\*

Remplacement de realloc()

*s*   \_In\_\
Type : curl\_strdup\_callback\*

Remplacement de strdup()

*c*   \_In\_\
Type : xcurl\_calloc\_memory\_callback\*

Remplacement de calloc()

<a id="retvalSection" />

### Valeur renvoyée

Si cette fonction renvoie une valeur différente de zéro, une erreur s'est produite et vous ne pouvez pas utiliser les autres fonctions curl.

<a id="remarksSection" />

## Remarques

Cette fonction est identique à [curl\_global\_init\_mem](https://curl.haxx.se/libcurl/c/curl_global_init_mem.html), à ceci près que cette version initialise XCurl avec des allocateurs de mémoire personnalisés.

XCurl repose sur le Gaming Runtime et ne peut donc pas être initialisé avant que vous n'ayez exécuté [XGameRuntimeInitialize](/fr/reference/system/xgameruntimeinit/functions/xgameruntimeuninitialize).

Partout où vous auriez inclus `curl.h` dans le code de votre jeu, vous devez le remplacer par `xcurl.h`.

<a id="requirementsSection" />

## Configuration requise

**En-tête :** XCurl.h

**Bibliothèque :** xcurl.lib

**Plateformes prises en charge :** Windows, consoles de la famille XBOX One et consoles XBOX Series

<a id="seealsoSection" />

## Voir aussi

[Vue d'ensemble de XCurl](/fr/build/console-features/networking/web-requests/intro-xcurl)\
[HTTP et WebSockets](/fr/build/console-features/networking/web-requests/http-networking)\
[curl](https://curl.se/)\
[xcurl\_global\_suspend](/fr/reference/networking/xcurl/functions/xcurl_global_suspend)\
[xcurl\_global\_resume](/fr/reference/networking/xcurl/functions/xcurl_global_resume)


## Related topics

- [xcurl_global_init_mem](/reference/networking/xcurl/functions/xcurl_global_init_mem.md)
- [xCurl overview](/build/console-features/networking/web-requests/intro-xcurl.md)
- [xCurl 概述](/zh-CN/build/console-features/networking/web-requests/intro-xcurl.md)
- [xCurl 개요](/ko/build/console-features/networking/web-requests/intro-xcurl.md)
- [Información general de xCurl](/es/build/console-features/networking/web-requests/intro-xcurl.md)
