X-Git-Url: https://git.exim.org/exim.git/blobdiff_plain/0599f9cfa6febfb0aa5c106510d72e49e72a65c4..4263f395efd136dece52d765dfcff3c96f17506e:/src/src/log.c diff --git a/src/src/log.c b/src/src/log.c index bfd1fef86..3a91ed295 100644 --- a/src/src/log.c +++ b/src/src/log.c @@ -2,7 +2,7 @@ * Exim - an Internet mail transport agent * *************************************************/ -/* Copyright (c) University of Cambridge 1995 - 2009 */ +/* Copyright (c) University of Cambridge 1995 - 2012 */ /* See the file NOTICE for conditions of use and distribution. */ /* Functions for writing log files. The code for maintaining datestamped @@ -528,11 +528,11 @@ Returns: length actually written, persisting an errno from write() */ ssize_t -write_to_fd_buf(int fd, uschar *buf, size_t length) +write_to_fd_buf(int fd, const uschar *buf, size_t length) { ssize_t wrote; size_t total_written = 0; -uschar *p = buf; +const uschar *p = buf; size_t left = length; while (1) @@ -1306,7 +1306,7 @@ misconfiguration. The first use of this is in ACL logic, "control = debug/tag=foo/opts=+expand" which can be combined with conditions, etc, to activate extra logging only -for certain sources. */ +for certain sources. The second use is inetd wait mode debug preservation. */ void debug_logging_activate(uschar *tag_name, uschar *opts) @@ -1316,7 +1316,7 @@ int fd = -1; if (debug_file) { debug_printf("DEBUGGING ACTIVATED FROM WITHIN CONFIG.\n" - "DEBUG: Tag=\"%s\" Opts=\"%s\"\n", tag_name, opts); + "DEBUG: Tag=\"%s\" Opts=\"%s\"\n", tag_name, opts ? opts : US""); return; }