]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib: istream-sized should log errors with its own name, not parent's name
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Mon, 16 May 2016 17:17:41 +0000 (20:17 +0300)
committerTimo Sirainen <timo.sirainen@dovecot.fi>
Thu, 23 Feb 2017 10:44:40 +0000 (12:44 +0200)
src/lib/istream-sized.c

index f060998c4b5a7a0b228bf291ef1e2a78b80117ff..b9c0164868b0e716e80e04d5141a51e36a7a7229 100644 (file)
@@ -91,7 +91,7 @@ static ssize_t i_stream_sized_read(struct istream_private *stream)
                error = sstream->error_callback(&data, sstream->error_context);
                io_stream_set_error(&stream->iostream, "%s", error);
                i_error("read(%s) failed: %s",
-                       i_stream_get_name(stream->parent),
+                       i_stream_get_name(&stream->istream),
                        stream->iostream.error);
                pos = left;
                stream->istream.eof = TRUE;
@@ -105,7 +105,7 @@ static ssize_t i_stream_sized_read(struct istream_private *stream)
                error = sstream->error_callback(&data, sstream->error_context);
                io_stream_set_error(&stream->iostream, "%s", error);
                i_error("read(%s) failed: %s",
-                       i_stream_get_name(stream->parent),
+                       i_stream_get_name(&stream->istream),
                        stream->iostream.error);
                stream->istream.stream_errno = EINVAL;
        }