Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
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
linux
linux-davinci
Commits
37e4c13b
Commit
37e4c13b
authored
Feb 18, 2005
by
Anton Altaparmakov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
NTFS: Fix a nasty runlist merge bug when merging two holes.
Signed-off-by:
Anton Altaparmakov
<
aia21@cantab.net
>
parent
d8ec785e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
2 deletions
+6
-2
fs/ntfs/ChangeLog
fs/ntfs/ChangeLog
+2
-1
fs/ntfs/runlist.c
fs/ntfs/runlist.c
+4
-1
No files found.
fs/ntfs/ChangeLog
View file @
37e4c13b
...
@@ -72,9 +72,10 @@ ToDo/Notes:
...
@@ -72,9 +72,10 @@ ToDo/Notes:
runlist. This allows us to find runlist elements with the runlist
runlist. This allows us to find runlist elements with the runlist
lock already held without having to drop and reacquire it around the
lock already held without having to drop and reacquire it around the
call. Adapt all callers.
call. Adapt all callers.
- Change time to u64 time.h::ntfs2utc() as it otherwise generates a
- Change time to u64
in
time.h::ntfs2utc() as it otherwise generates a
warning in the do_div() call on sparc32. Thanks to Meelis Roos for
warning in the do_div() call on sparc32. Thanks to Meelis Roos for
the report and analysis of the warning.
the report and analysis of the warning.
- Fix a nasty runlist merge bug when merging two holes.
2.1.22 - Many bug and race fixes and error handling improvements.
2.1.22 - Many bug and race fixes and error handling improvements.
...
...
fs/ntfs/runlist.c
View file @
37e4c13b
...
@@ -113,8 +113,11 @@ static inline BOOL ntfs_are_rl_mergeable(runlist_element *dst,
...
@@ -113,8 +113,11 @@ static inline BOOL ntfs_are_rl_mergeable(runlist_element *dst,
BUG_ON
(
!
dst
);
BUG_ON
(
!
dst
);
BUG_ON
(
!
src
);
BUG_ON
(
!
src
);
if
((
dst
->
lcn
<
0
)
||
(
src
->
lcn
<
0
))
/* Are we merging holes? */
if
((
dst
->
lcn
<
0
)
||
(
src
->
lcn
<
0
))
{
/* Are we merging holes? */
if
(
dst
->
lcn
==
LCN_HOLE
&&
src
->
lcn
==
LCN_HOLE
)
return
TRUE
;
return
FALSE
;
return
FALSE
;
}
if
((
dst
->
lcn
+
dst
->
length
)
!=
src
->
lcn
)
/* Are the runs contiguous? */
if
((
dst
->
lcn
+
dst
->
length
)
!=
src
->
lcn
)
/* Are the runs contiguous? */
return
FALSE
;
return
FALSE
;
if
((
dst
->
vcn
+
dst
->
length
)
!=
src
->
vcn
)
/* Are the runs misaligned? */
if
((
dst
->
vcn
+
dst
->
length
)
!=
src
->
vcn
)
/* Are the runs misaligned? */
...
...
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