summaryrefslogtreecommitdiff
path: root/mysys/my_redel.c
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-01-29 15:10:47 +0100
committerSergei Golubchik <sergii@pisem.net>2013-01-29 15:10:47 +0100
commit0af4b6c6ee2b8a61823478c0a56ebdfa52cae3cc (patch)
tree7b24eb150b9cca718c88edaabbfc6c8bb16fd015 /mysys/my_redel.c
parentcf20de000bdff07a34a373079991d24837423896 (diff)
parent52fbe44fbbe60ecaba6453884ec1ad32755d7a04 (diff)
downloadmariadb-git-0af4b6c6ee2b8a61823478c0a56ebdfa52cae3cc.tar.gz
5.5 merge
Diffstat (limited to 'mysys/my_redel.c')
-rw-r--r--mysys/my_redel.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/mysys/my_redel.c b/mysys/my_redel.c
index e4d88b70f38..3c68e69b46a 100644
--- a/mysys/my_redel.c
+++ b/mysys/my_redel.c
@@ -88,15 +88,11 @@ end:
int my_copystat(const char *from, const char *to, int MyFlags)
{
- struct stat statbuf;
+ MY_STAT statbuf;
- if (stat(from, &statbuf))
- {
- my_errno=errno;
- if (MyFlags & (MY_FAE+MY_WME))
- my_error(EE_STAT, MYF(ME_BELL+ME_WAITTANG),from,errno);
+ if (my_stat(from, &statbuf, MyFlags) == NULL)
return -1; /* Can't get stat on input file */
- }
+
if ((statbuf.st_mode & S_IFMT) != S_IFREG)
return 1;