From b28872e09fa74742f90eb4a6bcb7aa5204d321c2 Mon Sep 17 00:00:00 2001 From: Rangi42 Date: Tue, 5 May 2026 15:18:12 +0200 Subject: [PATCH] Fix `tools/make_patch.c` to be endian-independent --- tools/make_patch.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/make_patch.c b/tools/make_patch.c index 0d874fdcb..34c99b18f 100644 --- a/tools/make_patch.c +++ b/tools/make_patch.c @@ -148,7 +148,7 @@ struct Symbol *parse_symbols(const char *filename) { } buffer->size = 0; } - buffer_append(buffer, &c); + buffer_append(buffer, &(char){c}); } else if (state == SYM_VALUE) { // The symbol value has ended; wait to see if a name comes after it state = SYM_SPACE; @@ -386,7 +386,7 @@ struct Buffer *process_template( // "{...}" is a template command; buffer its contents buffer->size = 0; for (c = getc(input); c != EOF && c != '}'; c = getc(input)) { - buffer_append(buffer, &c); + buffer_append(buffer, &(char){c}); } buffer_append(buffer, &(char){'\0'}); // Interpret the command in the context of the current patch @@ -414,7 +414,7 @@ struct Buffer *process_template( c = '_'; } } - buffer_append(buffer, &c); + buffer_append(buffer, &(char){c}); } } buffer_append(buffer, &(char){'\0'});