Add panicf to plugin and codec API

rockbox-gerrit-noreply--- via rockbox-cvs <[email protected]> Tue, 21 Apr 2026 19:04:26 -0400
Newsgroups gmane.comp.systems.archos.rockbox.cvs
Message-ID <[email protected]>
commit 9ac6edf750a060b3e2c1f8fb4236a501f7aaf68a
Author: Aidan MacDonald <[email protected]>
Date:   Tue Apr 21 14:32:48 2026 +0100

    Add panicf to plugin and codec API
    
    Change-Id: I0e11ecaf8e18233f682f572f479cfdd141c99bd5

diff --git a/apps/codecs.c b/apps/codecs.c
index 7bd2de367e..c304b6eaf2 100644
--- a/apps/codecs.c
+++ b/apps/codecs.c
@@ -50,6 +50,7 @@
 #include "splash.h"
 #include "general.h"
 #include "rbpaths.h"
+#include "panic.h"
 
 #define LOGF_ENABLE
 #include "logf.h"
@@ -150,6 +151,7 @@ struct codec_api ci = {
 
     /* new stuff at the end, sort into place next time
        the API gets incompatible */
+    panicf,
 
 };
 
diff --git a/apps/plugin.c b/apps/plugin.c
index 6dfb9ce765..c2ab8ad322 100644
--- a/apps/plugin.c
+++ b/apps/plugin.c
@@ -49,6 +49,7 @@
 #include "core_keymap.h"
 #include "language.h"
 #include "statusbar-skinned.h"
+#include "panic.h"
 
 #if CONFIG_CHARGING
 #include "power.h"
@@ -870,6 +871,7 @@ static const struct plugin_api rockbox_api = {
 
     /* new stuff at the end, sort into place next time
        the API gets incompatible */
+    panicf,
 };
 
 static int plugin_buffer_handle;
diff --git a/apps/plugin.h b/apps/plugin.h
index 5dcbdcaee7..f6c3434692 100644
--- a/apps/plugin.h
+++ b/apps/plugin.h
@@ -1024,6 +1024,7 @@ struct plugin_api {
 
     /* new stuff at the end, sort into place next time
        the API gets incompatible */
+    void (*panicf)(const char *msg, ...);
 };
 
 /* plugin header */
diff --git a/lib/rbcodec/codecs/codecs.h b/lib/rbcodec/codecs/codecs.h
index 5e977c6f13..dad5cbe8f2 100644
--- a/lib/rbcodec/codecs/codecs.h
+++ b/lib/rbcodec/codecs/codecs.h
@@ -224,6 +224,7 @@ struct codec_api {
 
     /* new stuff at the end, sort into place next time
        the API gets incompatible */
+    void (*panicf)(const char *msg, ...);
 };
 
 /* codec header */
-- 
rockbox-cvs mailing list
[email protected]
https://lists.haxx.se/mailman/listinfo/rockbox-cvs