projects
/
project
/
bcm63xx
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1d7f2ec
)
fs/fat/fat_write: Fix curclust/newclust mix-up
author
Benoît Thébaudeau
<
[email protected]
>
Mon, 28 Sep 2015 13:45:30 +0000
(15:45 +0200)
committer
Tom Rini
<
[email protected]
>
Sun, 11 Oct 2015 21:12:07 +0000
(17:12 -0400)
curclust was used instead of newclust in the debug() calls and in one
CHECK_CLUST() call, which could skip a failure case.
Signed-off-by: Benoît Thébaudeau <
[email protected]
>
fs/fat/fat_write.c
patch
|
blob
|
history
diff --git
a/fs/fat/fat_write.c
b/fs/fat/fat_write.c
index e08cf83b05352ef5dc1cf57033815cdfdbc1c0d1..239984400174ff7077332b8d261dcca88a1718e8 100644
(file)
--- a/
fs/fat/fat_write.c
+++ b/
fs/fat/fat_write.c
@@
-721,7
+721,7
@@
set_contents(fsdata *mydata, dir_entry *dentptr, __u8 *buffer,
goto getit;
if (CHECK_CLUST(newclust, mydata->fatsize)) {
- debug("
cur
clust: 0x%x\n", newclust);
+ debug("
new
clust: 0x%x\n", newclust);
debug("Invalid FAT entry\n");
return 0;
}
@@
-754,8
+754,8
@@
getit:
filesize -= actsize;
buffer += actsize;
- if (CHECK_CLUST(
cur
clust, mydata->fatsize)) {
- debug("
curclust: 0x%x\n", cur
clust);
+ if (CHECK_CLUST(
new
clust, mydata->fatsize)) {
+ debug("
newclust: 0x%x\n", new
clust);
debug("Invalid FAT entry\n");
return 0;
}