Fix werror flag and warnings (#321)

* fix Werror flag
* strdup implementation fix
* fix irda and lfrdid printf
* remove unused position
* doubtful type fix
* type fix in EXTI interrupt
* fix warnings in CubeWB, need to fork ST repo
* onewire fixes
* fork STM32WB Cube repo
This commit is contained in:
coreglitch
2021-02-01 10:51:22 +03:00
committed by GitHub
parent 49057be9c9
commit 41219cc78e
10 changed files with 15 additions and 16 deletions

View File

@@ -318,7 +318,6 @@ uint64_t fs_file_tell(File* file) {
// Truncate file size to current pointer value
bool fs_file_truncate(File* file) {
FileData* filedata = NULL;
uint64_t position = 0;
file->internal_error_id = _get_file(fs_info, file, &filedata);
@@ -478,7 +477,7 @@ fs_common_info(const char* path, FileInfo* fileinfo, char* name, const uint16_t
if(fresult == SD_OK) {
fresult = f_stat(path, &_fileinfo);
if(fresult == FR_OK) {
if((FRESULT)fresult == FR_OK) {
if(fileinfo != NULL) {
fileinfo->date.value = _fileinfo.fdate;
fileinfo->time.value = _fileinfo.ftime;
@@ -592,7 +591,7 @@ FS_Error fs_get_fs_info(uint64_t* total_space, uint64_t* free_space) {
FATFS* fs;
fresult = f_getfree("0:/", &free_clusters, &fs);
if(fresult == FR_OK) {
if((FRESULT)fresult == FR_OK) {
uint32_t total_sectors = (fs->n_fatent - 2) * fs->csize;
uint32_t free_sectors = free_clusters * fs->csize;