milter-dk.patch 719 B

123456789101112131415161718192021222324252627
  1. Index: dk-filter/dk-filter.c
  2. --- dk-filter/dk-filter.c.orig 2006-05-19 23:42:05 +0200
  3. +++ dk-filter/dk-filter.c 2007-03-02 10:26:32 +0100
  4. @@ -61,7 +61,7 @@
  5. /* libmilter includes */
  6. #ifndef DEBUG
  7. -#include "libmilter/mfapi.h"
  8. +#include "milter/mfapi.h"
  9. #endif /* !DEBUG */
  10. /* libdk includes */
  11. @@ -2076,6 +2076,13 @@
  12. dfc = cc->cctx_msg;
  13. assert(dfc != NULL);
  14. + /* Determine the job ID for logging. */
  15. + if (dfc->mctx_jobid == 0 || strcmp(dfc->mctx_jobid, JOBIDUNKNOWN) == 0) {
  16. + char *jobid = smfi_getsymval(ctx, "i");
  17. + if (jobid != 0)
  18. + dfc->mctx_jobid = jobid;
  19. + }
  20. +
  21. /* get hostname; used in the X header and in new MIME boundaries */
  22. hostname = smfi_getsymval(ctx, "j");
  23. if (hostname == NULL)