fs/fat/fat_write: Fix return value on flush_fat_buffer() failure

Change-Id: I6e0440e8878b33c20e757df095ab0784a01a444c
Signed-off-by: Praveenkumar I <quic_ipkumar@quicinc.com>
This commit is contained in:
Praveenkumar I 2022-03-28 16:04:25 +05:30
parent 061829d7b8
commit b4c7b606e9

View file

@ -191,7 +191,7 @@ static __u32 get_fatent_value(fsdata *mydata, __u32 entry)
/* Write back the fatbuf to the disk */
if (mydata->fatbufnum != -1) {
if (flush_fat_buffer(mydata) < 0)
return -1;
return ret;
}
if (disk_read(startblock, getsize, bufptr) < 0) {