From d1b831e2329dc79505396b1eef20fef87225afdd Mon Sep 17 00:00:00 2001
From: "Ryan C. Gordon" <[EMAIL REDACTED]>
Date: Wed, 29 Nov 2023 15:56:26 -0500
Subject: [PATCH] include: Clarified documentation for two functions.
---
include/SDL3/SDL_gamepad.h | 5 ++++-
include/SDL3/SDL_touch.h | 2 +-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/include/SDL3/SDL_gamepad.h b/include/SDL3/SDL_gamepad.h
index 6baeaf305af5..bc1d9c47b654 100644
--- a/include/SDL3/SDL_gamepad.h
+++ b/include/SDL3/SDL_gamepad.h
@@ -314,7 +314,10 @@ extern DECLSPEC int SDLCALL SDL_ReloadGamepadMappings(void);
/**
* Get the mapping at a particular index.
*
- * \param count On return, set to the number of mappings returned. Can be NULL.
+ * You must free the returned pointer with SDL_free() when you are done with
+ * it, but you do _not_ free each string in the array.
+ *
+ * \param count a pointer filled in with the number of mappings returned, can be NULL.
* \returns an array of the mapping strings, NULL-terminated. Must be freed with SDL_free().
* Returns NULL on error.
*
diff --git a/include/SDL3/SDL_touch.h b/include/SDL3/SDL_touch.h
index 9f3d216016d6..26558c7dbfc5 100644
--- a/include/SDL3/SDL_touch.h
+++ b/include/SDL3/SDL_touch.h
@@ -74,7 +74,7 @@ typedef struct SDL_Finger
*
* This was fixed for Android in SDL 2.0.1.
*
- * \param count a pointer filled in with the number of devices returned
+ * \param count a pointer filled in with the number of devices returned, can be NULL.
* \returns a 0 terminated array of touch device IDs which should be
* freed with SDL_free(), or NULL on error; call SDL_GetError() for
* more details.