diff options
author | unknown <gbichot@bk-internal.mysql.com> | 2005-05-24 00:31:28 +0200 |
---|---|---|
committer | unknown <gbichot@bk-internal.mysql.com> | 2005-05-24 00:31:28 +0200 |
commit | 0e4afc241205719296c39b0b1b0694d2baaccf21 (patch) | |
tree | 5da5eb79642bfdfba40fd1c24219b19bf4bb7580 /mysys/my_open.c | |
parent | ad9eba227d7ba62e7f25ae35319191a5fd1452b6 (diff) | |
parent | b6c1f2302ab77e6cfd37bd05f8444ff0c82bc459 (diff) | |
download | mariadb-git-0e4afc241205719296c39b0b1b0694d2baaccf21.tar.gz |
Merge bk-internal.mysql.com:/data0/bk/mysql-4.1
into bk-internal.mysql.com:/data0/bk/mysql-5.0
BitKeeper/etc/gone:
auto-union
BitKeeper/etc/logging_ok:
auto-union
mysql-test/r/lowercase_table.result:
Auto merged
mysql-test/t/lowercase_table.test:
Auto merged
mysys/my_open.c:
Auto merged
Diffstat (limited to 'mysys/my_open.c')
-rw-r--r-- | mysys/my_open.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/mysys/my_open.c b/mysys/my_open.c index a5cd3811bbf..7fc5282838f 100644 --- a/mysys/my_open.c +++ b/mysys/my_open.c @@ -46,6 +46,13 @@ File my_open(const char *FileName, int Flags, myf MyFlags) DBUG_PRINT("my",("Name: '%s' Flags: %d MyFlags: %d", FileName, Flags, MyFlags)); #if defined(MSDOS) || defined(__WIN__) || defined(__EMX__) || defined(OS2) + /* + if we are not creating, then we need to use my_access to make + sure the file exists since Windows doesn't handle files like + "com1.sym" very well + */ + if (! (Flags & O_CREAT) && my_access(FileName, F_OK)) + return -1; if (Flags & O_SHARE) fd = sopen((my_string) FileName, (Flags & ~O_SHARE) | O_BINARY, SH_DENYNO, MY_S_IREAD | MY_S_IWRITE); |