Skip to contentSkip to conversation

ppc/amigaone: Constify default_env

PATCH In review BALATON Zoltan 3 participants 3 messages Mar 14, 2025 – Mar 17, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ppc/amigaone: Constify default_env

The variable holding default env is not supposed to be written.

---
 hw/ppc/amigaone.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
hw/ppc/amigaone.c +1 -1
index 5d787c3059..e9407a51b5 100644
@@ -63,7 +63,7 @@ static const char dummy_fw[] = {
 #define NVRAM_ADDR 0xfd0e0000
 #define NVRAM_SIZE (4 * KiB)
 
-static char default_env[] =
+static const char default_env[] =
     "baudrate=115200\0"
     "stdout=vga\0"
     "stdin=ps2kbd\0"
Signature · 1 line
2.41.3
Reviewed-by on v1 1/1
#1 lore raw
Quoted 3 lines · BALATON Zoltan

The variable holding default env is not supposed to be written.

Quoted 17 lines
---
 hw/ppc/amigaone.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
hw/ppc/amigaone.c +1 -1
index 5d787c3059..e9407a51b5 100644
@@ -63,7 +63,7 @@ static const char dummy_fw[] = {
 #define NVRAM_ADDR 0xfd0e0000
 #define NVRAM_SIZE (4 * KiB)
 
-static char default_env[] =
+static const char default_env[] =
     "baudrate=115200\0"
     "stdout=vga\0"
     "stdin=ps2kbd\0"