Description: testsuite/gna: fix vpi prototypes
Author: Tristan Gingold <tgingold@free.fr>
Origin: upstream, https://github.com/ghdl/ghdl/commit/a9fe853e63229603a8958fd80ff8b996dd49c950
Last-Update: 2024-11-15
diff --git a/testsuite/gna/issue450/vpi2.c b/testsuite/gna/issue450/vpi2.c
index 0debb546b..f1d652bb7 100644
--- a/testsuite/gna/issue450/vpi2.c
+++ b/testsuite/gna/issue450/vpi2.c
@@ -40,7 +40,7 @@ void printContent (vpiHandle parent)
     }
 }
 
-void printModules()
+PLI_INT32 printModules(s_cb_data *cb)
 {
   vpiHandle topModIterator;
   vpiHandle topModHandle;
@@ -53,7 +53,7 @@ void printModules()
   vpi_printf ("got to here1 \n");
   if (!topModIterator)
     {
-      return;
+      return -1;
     }
 
   /* use vpi_scan to iterate throught modules */
@@ -64,6 +64,8 @@ void printModules()
 
       printContent (topModHandle);
     }
+
+  return 0;
 }
 
 
diff --git a/testsuite/gna/issue98/vpi1.c b/testsuite/gna/issue98/vpi1.c
index 0adae07fe..a14b89df2 100644
--- a/testsuite/gna/issue98/vpi1.c
+++ b/testsuite/gna/issue98/vpi1.c
@@ -1,8 +1,8 @@
 #include <stdio.h>
 #include <vpi_user.h>
 
-void
-vpi_proc (void)
+PLI_INT32
+vpi_proc (s_cb_data *cb)
 {
   vpiHandle net;
   s_vpi_value val;
@@ -11,11 +11,12 @@ vpi_proc (void)
   if (net == NULL)
     {
       printf ("cannot get net\n");
-      return;
+      return -1;
     }
   val.format = vpiBinStrVal;
   vpi_get_value (net, &val);
   printf ("value: %s\n", val.value.str);
+  return 0;
 }
 
 void my_handle_register()
