aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
diff options
context:
space:
mode:
authorRoy Ben-Shabat <Roy@Twine-s.com>2020-12-13 01:36:14 +0200
committerRoy Ben-Shabat <Roy@Twine-s.com>2020-12-13 01:36:14 +0200
commit10ed2886c61b94ed0ec294e40d260d2a69ef2cc1 (patch)
treefd439c24cf0cd48350f42cbfa54aeb90d563e5da /Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
parent2a73ff05b9bf95da0f9fe10aa7823bd70f01f01e (diff)
parenta793aababd2b255dda42540715792167164e1e94 (diff)
downloadTango-10ed2886c61b94ed0ec294e40d260d2a69ef2cc1.tar.gz
Tango-10ed2886c61b94ed0ec294e40d260d2a69ef2cc1.zip
Merge branch 'master' of https://twinetfs.visualstudio.com/_git/Tango
Diffstat (limited to 'Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c')
-rw-r--r--Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
index f3d42b01a..a59a14dcf 100644
--- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
+++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
@@ -794,8 +794,11 @@ FRESULT FileWrite(void * buffer, uint16_t size,char *path, uint32_t timeout)
{
LOG_ERROR (Fresult,"fwrite error");
}
- //LOG_ERROR (Bytes,"f_write ok no of bytes");
- Report("f_write ok no of bytes", __FILE__, __LINE__, Bytes, RpWarning, (int)size, 0);
+ else
+ {
+ //LOG_ERROR (Bytes,"f_write ok no of bytes");
+ Report("f_write ok no of bytes", __FILE__, __LINE__, Bytes, RpWarning, (int)size, 0);
+ }
f_close(FileHandle);
}
else
@@ -875,12 +878,14 @@ FRESULT FileRead(char *path, uint32_t *Size, void **Buffer)
}
else
{
- LOG_ERROR (Fresult,"malloc error");
+ Report("malloc error", __FILE__, __LINE__, Fresult, RpWarning, (int)fno->fsize, 0);
+ Fresult = FR_DENIED;
}
}
else
{
- LOG_ERROR (Fresult,"f_stat error");
+ Report("f_stat error", __FILE__, __LINE__, Fresult, RpWarning, (int)0, 0);
+ Fresult = FR_DENIED;
}
my_free(fno);
return Fresult;