summaryrefslogtreecommitdiff
path: root/storage/archive/azio.c
diff options
context:
space:
mode:
authorSergey Vojtovich <sergey.vojtovich@oracle.com>2011-06-03 11:49:05 +0400
committerSergey Vojtovich <sergey.vojtovich@oracle.com>2011-06-03 11:49:05 +0400
commit819d6b735e52b0ddaae4b4feee16196b570f19ea (patch)
tree02d778d3a688eecb4f44b4c982740a82242a98e4 /storage/archive/azio.c
parenta483b5bfa945ec0741a2053cd1efe165eb22b5b3 (diff)
parent2ab0abd26820dbdf102be2ac7a6f455849ad66e3 (diff)
downloadmariadb-git-819d6b735e52b0ddaae4b4feee16196b570f19ea.tar.gz
Merge.
Diffstat (limited to 'storage/archive/azio.c')
-rw-r--r--storage/archive/azio.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/storage/archive/azio.c b/storage/archive/azio.c
index 1e2753027dc..5fc9bc875f8 100644
--- a/storage/archive/azio.c
+++ b/storage/archive/azio.c
@@ -114,6 +114,15 @@ int az_open (azio_stream *s, const char *path, int Flags, File fd)
errno = 0;
s->file = fd < 0 ? my_open(path, Flags, MYF(0)) : fd;
+ DBUG_EXECUTE_IF("simulate_archive_open_failure",
+ {
+ if (s->file >= 0)
+ {
+ my_close(s->file, MYF(0));
+ s->file= -1;
+ my_errno= EMFILE;
+ }
+ });
if (s->file < 0 )
{