File: fix-gcc-14-ftbfs.patch

package info (click to toggle)
tilem 2.0-5.1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 4,136 kB
  • sloc: ansic: 27,147; makefile: 740; sh: 344; xml: 315
file content (21 lines) | stat: -rw-r--r-- 934 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
Description: Fix FTBFS with GCC 14 due to an incompatible pointer type
 When initializing macro->actions[n], instead of initializing it as a char,
 initialize it with the proper type.
 This patch has also been tested with nascent releases of GCC 15.
Author: Simon Quigley <tsimonq2@debian.org>
Origin: vendor
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1075572
Last-Update: 2025-02-28
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- a/gui/macro.c
+++ b/gui/macro.c
@@ -86,7 +86,7 @@ void tilem_macro_add_action(TilemMacro*
 	macro->actions = tilem_macro_actions_new(macro, n + 1);
 
 	/* Then we need to save the action */	
-	macro->actions[n] =  g_new(char, strlen(value)); /* FIXME : gcc says : "assignment from incompatible pointer type" ??? */
+	macro->actions[n] = g_new(TilemMacroAtom, 1);
 	macro->actions[n]->value = g_strdup(value);
 	macro->actions[n]->type = type;
 	macro->n++;