diff options
author | unknown <monty@mysql.com/narttu.mysql.fi> | 2007-01-23 21:13:26 +0200 |
---|---|---|
committer | unknown <monty@mysql.com/narttu.mysql.fi> | 2007-01-23 21:13:26 +0200 |
commit | ca42b36cc99fa0fb1d12a3150316bf3164909a07 (patch) | |
tree | 09269afde6ea92811b9a270afbfa86d3dc42dcc2 /mysys/my_pread.c | |
parent | b635df555adec7ebdc4cd40e102d51006c802639 (diff) | |
parent | 345959c660d7401c9dc991a2c572ba145d6e199c (diff) | |
download | mariadb-git-ca42b36cc99fa0fb1d12a3150316bf3164909a07.tar.gz |
Merge with new version
storage/myisam/mi_rsamepos.c:
Auto merged
include/m_string.h:
Automatic merge
include/maria.h:
manual merge
include/my_base.h:
Automatic merge
include/my_sys.h:
Automatic merge
mysys/mf_keycache.c:
Automatic merge
mysys/my_pread.c:
Automatic merge
sql/filesort.cc:
Automatic merge
sql/gen_lex_hash.cc:
Automatic merge
sql/mysqld.cc:
Automatic merge
sql/uniques.cc:
Automatic merge
storage/maria/Makefile.am:
manual_merge
storage/maria/ha_maria.cc:
Automatic merge
storage/maria/ma_check.c:
manual merge
storage/maria/ma_close.c:
manual merge
storage/maria/ma_create.c:
manual merge
storage/maria/ma_delete.c:
manual merge
storage/maria/ma_delete_all.c:
Automatic merge
storage/maria/ma_dynrec.c:
manual merge
storage/maria/ma_extra.c:
Automatic merge
storage/maria/ma_ft_boolean_search.c:
manual merge
storage/maria/ma_init.c:
Automatic merge
storage/maria/ma_key.c:
manual merge
storage/maria/ma_keycache.c:
manual merge
storage/maria/ma_locking.c:
Automatic merge
storage/maria/ma_open.c:
manual merge
storage/maria/ma_packrec.c:
manual merge
storage/maria/ma_page.c:
Automatic merge
storage/maria/ma_range.c:
Automatic merge
storage/maria/ma_rkey.c:
manual merge
storage/maria/ma_rsamepos.c:
manual merge
storage/maria/ma_sort.c:
manual merge
storage/maria/ma_statrec.c:
Automatic merge
storage/maria/ma_test2.c:
Automatic merge
storage/maria/ma_test3.c:
Automatic merge
storage/maria/ma_test_all.sh:
Use new version
storage/maria/ma_unique.c:
Automatic merge
storage/maria/ma_update.c:
Automatic merge
storage/maria/ma_write.c:
manual merge
storage/maria/maria_chk.c:
manual merge
storage/maria/maria_def.h:
manual merge
Added length pointer to _ma_page_get_block_info()
storage/maria/maria_ftdump.c:
Automatic merge
storage/maria/maria_pack.c:
manual merge
storage/myisam/mi_check.c:
Automatic merge
storage/myisam/mi_create.c:
Automatic merge
storage/myisam/mi_test2.c:
Automatic merge
storage/myisam/sort.c:
Automatic merge
Diffstat (limited to 'mysys/my_pread.c')
-rw-r--r-- | mysys/my_pread.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/mysys/my_pread.c b/mysys/my_pread.c index e36713b599f..61735f439c8 100644 --- a/mysys/my_pread.c +++ b/mysys/my_pread.c @@ -52,7 +52,7 @@ uint my_pread(File Filedes, byte *Buffer, uint Count, my_off_t offset, if (!error) /* Seek was successful */ { if ((readbytes = (uint) read(Filedes, Buffer, Count)) == -1L) - my_errno= errno; + my_errno= errno ? errno : -1; /* We should seek back, even if read failed. If this fails, @@ -68,7 +68,7 @@ uint my_pread(File Filedes, byte *Buffer, uint Count, my_off_t offset, #else if ((error= ((readbytes = (uint) pread(Filedes, Buffer, Count, offset)) != Count))) - my_errno= errno; + my_errno= errno ? errno : -1; #endif if (error || readbytes != Count) { @@ -88,8 +88,10 @@ uint my_pread(File Filedes, byte *Buffer, uint Count, my_off_t offset, my_error(EE_READ, MYF(ME_BELL+ME_WAITTANG), my_filename(Filedes),my_errno); else if (MyFlags & (MY_NABP | MY_FNABP)) + { my_error(EE_EOFERR, MYF(ME_BELL+ME_WAITTANG), my_filename(Filedes),my_errno); + } } if ((int) readbytes == -1 || (MyFlags & (MY_FNABP | MY_NABP))) DBUG_RETURN(MY_FILE_ERROR); /* Return with error */ |