projects
/
lwext4.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
44ce3df
)
ext4_fs: fix possible overflow
author
gkostka
<kostka.grzegorz@gmail.com>
Tue, 12 Apr 2016 15:43:13 +0000
(17:43 +0200)
committer
gkostka
<kostka.grzegorz@gmail.com>
Tue, 12 Apr 2016 15:43:13 +0000
(17:43 +0200)
include/ext4_fs.h
patch
|
blob
|
history
diff --git
a/include/ext4_fs.h
b/include/ext4_fs.h
index b598c5e1430ad270c7c5e79ccf7dc638ef566ca6..9653f47878c514da1804088f3fb7d348d09851ce 100644
(file)
--- a/
include/ext4_fs.h
+++ b/
include/ext4_fs.h
@@
-94,7
+94,7
@@
struct ext4_inode_ref {
static inline uint32_t ext4_fs_addr_to_idx_bg(struct ext4_sblock *s,
ext4_fsblk_t baddr)
{
- if (ext4_get32(s, first_data_block))
+ if (ext4_get32(s, first_data_block)
&& baddr
)
baddr--;
return baddr % ext4_get32(s, blocks_per_group);