commit 3c8e120e8c207d7f235ca6d15f189eb237009d34
parent fa9f0a4ee2d3cf9414d37a252ef6b408b1c88f14
Author: Jacki <jacki@thejackimonster.de>
Date: Mon, 22 Apr 2024 16:16:13 +0200
Give write access to file handle in callbacks
Signed-off-by: Jacki <jacki@thejackimonster.de>
Diffstat:
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/include/gnunet/gnunet_chat_lib.h b/include/gnunet/gnunet_chat_lib.h
@@ -372,13 +372,13 @@ typedef enum GNUNET_GenericReturnValue
* Method called during an upload of a specific file in a chat to share it.
*
* @param[in,out] cls Closure from #GNUNET_CHAT_context_send_file
- * @param[in] file Chat file
+ * @param[in,out] file Chat file
* @param[in] completed Amount of the file being uploaded (in bytes)
* @param[in] size Full size of the uploading file (in bytes)
*/
typedef void
(*GNUNET_CHAT_FileUploadCallback) (void *cls,
- const struct GNUNET_CHAT_File *file,
+ struct GNUNET_CHAT_File *file,
uint64_t completed,
uint64_t size);
@@ -386,13 +386,13 @@ typedef void
* Method called during a download of a specific file in a chat which was shared.
*
* @param[in,out] cls Closure from #GNUNET_CHAT_file_start_download
- * @param[in] file Chat file
+ * @param[in,out] file Chat file
* @param[in] completed Amount of the file being downloaded (in bytes)
* @param[in] size Full size of the downloading file (in bytes)
*/
typedef void
(*GNUNET_CHAT_FileDownloadCallback) (void *cls,
- const struct GNUNET_CHAT_File *file,
+ struct GNUNET_CHAT_File *file,
uint64_t completed,
uint64_t size);
diff --git a/tests/test_gnunet_chat_file.c b/tests/test_gnunet_chat_file.c
@@ -54,7 +54,7 @@ on_gnunet_chat_file_send_it(void *cls,
void
on_gnunet_chat_file_send_upload(void *cls,
- const struct GNUNET_CHAT_File *file,
+ struct GNUNET_CHAT_File *file,
uint64_t completed,
uint64_t size)
{