shithub: choc

Download patch

ref: 44b80b2a7a1b2a4866267ca7d7bda11ae926a4bb
parent: 1758e8908027337097aacce0d150d30aa7c3a6b6
author: Turo Lamminen <turotl@gmail.com>
date: Tue Mar 6 13:45:08 EST 2018

Make TXT_SetButtonLabel label parameter const

--- a/textscreen/txt_button.c
+++ b/textscreen/txt_button.c
@@ -93,7 +93,7 @@
     NULL,
 };
 
-void TXT_SetButtonLabel(txt_button_t *button, char *label)
+void TXT_SetButtonLabel(txt_button_t *button, const char *label)
 {
     free(button->label);
     button->label = strdup(label);
--- a/textscreen/txt_button.h
+++ b/textscreen/txt_button.h
@@ -67,7 +67,7 @@
  * @param label        The new label (UTF-8 format).
  */
 
-void TXT_SetButtonLabel(txt_button_t *button, char *label);
+void TXT_SetButtonLabel(txt_button_t *button, const char *label);
 
 #endif /* #ifndef TXT_BUTTON_H */