This is an automated email from the ASF dual-hosted git repository.

mxmanghi pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tcl-rivet.git


The following commit(s) were added to refs/heads/master by this push:
     new ba1c4c5  Using the named fields form of structure definition for 
RivetChan
ba1c4c5 is described below

commit ba1c4c5dab9cb6ea733706c6c47fb747bae81c01
Author: Massimo Manghi <[email protected]>
AuthorDate: Mon Feb 16 08:44:41 2026 +0100

    Using the named fields form of structure definition for RivetChan
---
 src/mod_rivet_ng/mod_rivet.h    |  2 +-
 src/mod_rivet_ng/rivetChannel.c | 36 +++++++++++++++++++-----------------
 2 files changed, 20 insertions(+), 18 deletions(-)

diff --git a/src/mod_rivet_ng/mod_rivet.h b/src/mod_rivet_ng/mod_rivet.h
index 3966d1e..1dddde7 100644
--- a/src/mod_rivet_ng/mod_rivet.h
+++ b/src/mod_rivet_ng/mod_rivet.h
@@ -334,4 +334,4 @@ Tcl_Obj* Rivet_CurrentServerRec (Tcl_Interp* interp, 
server_rec* s);
 
 #define RIVET_MPM_BRIDGE_COMPOSE(bridge) "/mpm/rivet_",bridge,"_mpm.so"
 
-#endif /* MOD_RIVET_H */
+#endif /* __mod_rivet_h__ */
diff --git a/src/mod_rivet_ng/rivetChannel.c b/src/mod_rivet_ng/rivetChannel.c
index 363e770..6477baa 100644
--- a/src/mod_rivet_ng/rivetChannel.c
+++ b/src/mod_rivet_ng/rivetChannel.c
@@ -24,6 +24,7 @@
 #ifdef HAVE_CONFIG_H
 #include <rivet_config.h>
 #endif
+
 #include <apr_general.h>
 #include <apr_thread_proc.h>
 #include <apr_thread_cond.h>
@@ -102,21 +103,22 @@ RivetChan_GetHandleProc(ClientData instancedata, int 
direction, ClientData *hand
 }
 
 Tcl_ChannelType RivetChan = {
-    "apache_channel",           /* typeName */
-    TCL_CHANNEL_VERSION_5,      /* channel type version */
-    TCL_CLOSEPROC,              /* close proc */
-    RivetChan_InputProc,        /* input proc */
-    RivetChan_OutputProc,       /* output proc */
-    NULL,                       /* seek proc - can be null */
-    RivetChan_SetOptionProc,    /* set option proc - can be null */
-    NULL,                       /* get option proc - can be null */
-    RivetChan_WatchProc,        /* watch proc */
-    RivetChan_GetHandleProc,    /* get handle proc */
-    RivetChan_Close2Proc,       /* close 2 proc - can be null */
-    NULL,                       /* block mode proc - can be null */
-    NULL,                       /* flush proc - can be null */
-    NULL,                       /* handler proc - can be null */
-    NULL,                       /* wide seek proc - can be null if seekproc 
is*/
-    NULL,                       /* thread action proc - can be null */
-    NULL                        /* truncate proc */
+    .typeName       =   "apache_channel",
+    .version        =   TCL_CHANNEL_VERSION_5,
+    .closeProc      =   TCL_CLOSEPROC,
+    .inputProc      =   RivetChan_InputProc,
+    .outputProc     =   RivetChan_OutputProc,
+    .seekProc       =   NULL,
+    .setOptionProc  =   RivetChan_SetOptionProc,
+    .getOptionProc  =   NULL,
+    .watchProc      =   RivetChan_WatchProc,
+    .getHandleProc  =   RivetChan_GetHandleProc,
+    .close2Proc     =   RivetChan_Close2Proc,
+    .blockModeProc  =   NULL,
+    .flushProc      =   NULL,
+    .handlerProc    =   NULL,
+    .wideSeekProc   =   NULL,
+    .threadActionProc = NULL,
+    .truncateProc   =   NULL
 };
+


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to