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
15a20367
Commit
15a20367
authored
Feb 23, 2019
by
Marko Mäkelä
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
buf_page_get_zip(): Deduplicate some code
parent
2c8d9a4e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
11 deletions
+3
-11
storage/innobase/buf/buf0buf.cc
storage/innobase/buf/buf0buf.cc
+3
-11
No files found.
storage/innobase/buf/buf0buf.cc
View file @
15a20367
...
...
@@ -3782,18 +3782,10 @@ buf_page_get_zip(
ut_ad
(
!
buf_pool_watch_is_sentinel
(
buf_pool
,
bpage
));
switch
(
buf_page_get_state
(
bpage
))
{
case
BUF_BLOCK_POOL_WATCH
:
case
BUF_BLOCK_NOT_USED
:
case
BUF_BLOCK_READY_FOR_USE
:
case
BUF_BLOCK_MEMORY
:
case
BUF_BLOCK_REMOVE_HASH
:
ut_error
;
case
BUF_BLOCK_ZIP_PAGE
:
case
BUF_BLOCK_ZIP_DIRTY
:
buf_block_fix
(
bpage
);
block_mutex
=
&
buf_pool
->
zip_mutex
;
mutex_enter
(
block_mutex
);
goto
got_block
;
case
BUF_BLOCK_FILE_PAGE
:
/* Discard the uncompressed page frame if possible. */
...
...
@@ -3808,16 +3800,16 @@ buf_page_get_zip(
__FILE__
,
__LINE__
);
block_mutex
=
&
((
buf_block_t
*
)
bpage
)
->
mutex
;
mutex_enter
(
block_mutex
);
goto
got_block
;
default:
break
;
}
ut_error
;
goto
err_exit
;
got_block:
mutex_enter
(
block_mutex
);
must_read
=
buf_page_get_io_fix
(
bpage
)
==
BUF_IO_READ
;
rw_lock_s_unlock
(
hash_lock
);
...
...
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