Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
42943191
Commit
42943191
authored
Apr 14, 2003
by
Anton Altaparmakov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
NTFS: load_attribute_list() bug fix from Szaka.
parent
253ee740
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
fs/ntfs/ChangeLog
fs/ntfs/ChangeLog
+2
-0
fs/ntfs/attrib.c
fs/ntfs/attrib.c
+3
-5
No files found.
fs/ntfs/ChangeLog
View file @
42943191
...
@@ -24,6 +24,8 @@ ToDo:
...
@@ -24,6 +24,8 @@ ToDo:
- super.c::parse_ntfs_boot_sector(): Correct the check for 64-bit
- super.c::parse_ntfs_boot_sector(): Correct the check for 64-bit
clusters. (Philipp Thomas)
clusters. (Philipp Thomas)
- attrib.c::load_attribute_list(): Fix bug when initialized_size is a
multiple of the block_size but not the cluster size. (Szaka)
2.1.2 - Important bug fixes aleviating the hangs in statfs.
2.1.2 - Important bug fixes aleviating the hangs in statfs.
...
...
fs/ntfs/attrib.c
View file @
42943191
...
@@ -1238,11 +1238,9 @@ int load_attribute_list(ntfs_volume *vol, run_list *run_list, u8 *al,
...
@@ -1238,11 +1238,9 @@ int load_attribute_list(ntfs_volume *vol, run_list *run_list, u8 *al,
unsigned
char
block_size_bits
=
sb
->
s_blocksize_bits
;
unsigned
char
block_size_bits
=
sb
->
s_blocksize_bits
;
ntfs_debug
(
"Entering."
);
ntfs_debug
(
"Entering."
);
#ifdef DEBUG
if
(
!
vol
||
!
run_list
||
!
al
||
size
<=
0
||
initialized_size
<
0
||
if
(
!
vol
||
!
run_list
||
!
al
||
size
<=
0
||
initialized_size
<
0
||
initialized_size
>
size
)
initialized_size
>
size
)
return
-
EINVAL
;
return
-
EINVAL
;
#endif
if
(
!
initialized_size
)
{
if
(
!
initialized_size
)
{
memset
(
al
,
0
,
size
);
memset
(
al
,
0
,
size
);
return
0
;
return
0
;
...
@@ -1273,8 +1271,8 @@ int load_attribute_list(ntfs_volume *vol, run_list *run_list, u8 *al,
...
@@ -1273,8 +1271,8 @@ int load_attribute_list(ntfs_volume *vol, run_list *run_list, u8 *al,
"read attribute list."
);
"read attribute list."
);
goto
err_out
;
goto
err_out
;
}
}
if
(
al
+
block_size
>
al_end
)
if
(
al
+
block_size
>
=
al_end
)
goto
do_
parti
al
;
goto
do_
fin
al
;
memcpy
(
al
,
bh
->
b_data
,
block_size
);
memcpy
(
al
,
bh
->
b_data
,
block_size
);
brelse
(
bh
);
brelse
(
bh
);
al
+=
block_size
;
al
+=
block_size
;
...
@@ -1288,7 +1286,7 @@ int load_attribute_list(ntfs_volume *vol, run_list *run_list, u8 *al,
...
@@ -1288,7 +1286,7 @@ int load_attribute_list(ntfs_volume *vol, run_list *run_list, u8 *al,
done:
done:
up_read
(
&
run_list
->
lock
);
up_read
(
&
run_list
->
lock
);
return
err
;
return
err
;
do_
parti
al:
do_
fin
al:
if
(
al
<
al_end
)
{
if
(
al
<
al_end
)
{
/* Partial block. */
/* Partial block. */
memcpy
(
al
,
bh
->
b_data
,
al_end
-
al
);
memcpy
(
al
,
bh
->
b_data
,
al_end
-
al
);
...
...
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