/* needs to be published for other callers */
#define MULTIPART_BOUNDARY 1
+#define MULTIPART_MODULE_NEXTMOD 1
+
+static msgproc_module *nextmod;
struct multipart_state {
char *boundary;
msgproc_setpriv(m, (void*)mps);
}
+static void
+setnextmod(int type, void *data, size_t size)
+{
+ if (type != MULTIPART_MODULE_NEXTMOD) return;
+ nextmod = (msgproc_module *)data;
+}
+
static void
setboundary(msgproc *m, int type, void *data, size_t size)
{
msgproc_module msgproc_multipart = {
MSGPROC_MULTIPART, /* type */
NULL, /* module init */
- NULL, /* set module parameter */
+ setnextmod, /* set module parameter */
multipart_start, /* start module instance */
setboundary, /* set module instance parameter */
multipart_process, /* process data */