Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
1d21b221
Commit
1d21b221
authored
Jun 15, 2016
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-10001 my_b_seek() may not work correctly after my_b_read() hits EOF
applied the patch from David Gow
parent
ecdf46da
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
mysys/mf_iocache.c
mysys/mf_iocache.c
+3
-0
No files found.
mysys/mf_iocache.c
View file @
1d21b221
...
...
@@ -507,6 +507,7 @@ int _my_b_read(register 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
);
}
/*
...
...
@@ -524,6 +525,7 @@ int _my_b_read(register 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
;
...
...
@@ -572,6 +574,7 @@ int _my_b_read(register 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
);
}
/*
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment