summaryrefslogtreecommitdiff
path: root/mysys/mf_iocache.c
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2016-06-30 16:38:05 +0200
committerSergei Golubchik <serg@mariadb.org>2016-06-30 16:38:05 +0200
commit932646b1ff6a8f5815a961340a9e1ee4702f5b44 (patch)
tree5bc42ace8ae1f7e4d00baffd468bdb7564e851f1 /mysys/mf_iocache.c
parent0bb30f3603b519780eaf3fe0527b1c6af285229a (diff)
parent33492ec8d4e2077cf8e07d0628a959d8729bd1f9 (diff)
downloadmariadb-git-932646b1ff6a8f5815a961340a9e1ee4702f5b44.tar.gz
Merge branch '10.1' into 10.2
Diffstat (limited to 'mysys/mf_iocache.c')
-rw-r--r--mysys/mf_iocache.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/mysys/mf_iocache.c b/mysys/mf_iocache.c
index af1e0830aee..635e544d367 100644
--- a/mysys/mf_iocache.c
+++ b/mysys/mf_iocache.c
@@ -614,6 +614,7 @@ int _my_b_cache_read(IO_CACHE *info, uchar *Buffer, size_t Count)
{
/* End of file. Return, what we did copy from the buffer. */
info->error= (int) left_length;
+ info->seek_not_done=1;
DBUG_RETURN(1);
}
/*
@@ -631,6 +632,7 @@ int _my_b_cache_read(IO_CACHE *info, uchar *Buffer, size_t Count)
*/
info->error= (read_length == (size_t) -1 ? -1 :
(int) (read_length+left_length));
+ info->seek_not_done=1;
DBUG_RETURN(1);
}
Count-=length;
@@ -683,6 +685,7 @@ int _my_b_cache_read(IO_CACHE *info, uchar *Buffer, size_t Count)
/* For a read error, return -1, otherwise, what we got in total. */
info->error= length == (size_t) -1 ? -1 : (int) (length+left_length);
info->read_pos=info->read_end=info->buffer;
+ info->seek_not_done=1;
DBUG_RETURN(1);
}
/*
@@ -1925,6 +1928,7 @@ void die(const char* fmt, ...)
fprintf(stderr,"Error:");
vfprintf(stderr, fmt,va_args);
fprintf(stderr,", errno=%d\n", errno);
+ va_end(va_args);
exit(1);
}