Skip to content

Commit ea7c568

Browse files
committed
fix esp8266/rp2040 compilation errors
1 parent 3624d12 commit ea7c568

File tree

2 files changed

+5
-12
lines changed

2 files changed

+5
-12
lines changed

src/libunpacker/LibUnpacker.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -665,7 +665,7 @@ int TarUnpacker::tarHeaderCallBack( TAR::header_translated_t *header, CC_UNUSED
665665
log_v("[TAR] Creating %s", tar_file_path);
666666
}
667667

668-
untarredFile = tarFS->open(tar_file_path, fs_file_wplus);
668+
untarredFile = tarFS->open(tar_file_path, fs_file_write);
669669
if(!untarredFile) {
670670
log_e("[ERROR] in tarHeaderCallBack: Could not open [%s] for write, filesystem full?", tar_file_path);
671671
setError( ESP32_TARGZ_FS_ERROR );
@@ -1493,7 +1493,7 @@ bool GzUnpacker::gzExpander( fs_FS sourceFS, const char* sourceFile, fs_FS destF
14931493
log_v("[GZ INFO] Deleting %s as it is in the way", destFile);
14941494
destFS.remove( destFile );
14951495
}
1496-
fs_File outfile = destFS.open( destFile, fs_file_wplus );
1496+
fs_File outfile = destFS.open( destFile, fs_file_write );
14971497
if(!outfile) {
14981498
log_e("[GZ ERROR] in gzExpander: cannot create destination file, no space left on device ?");
14991499
gz.close();
@@ -1591,7 +1591,7 @@ bool GzUnpacker::gzStreamExpander( Stream* sourceStream, fs_FS destFS, const cha
15911591
log_v("[GZ INFO] Deleting %s as it is in the way", destFile);
15921592
destFS.remove( destFile );
15931593
}
1594-
fs_File outFile = destFS.open(destFile, fs_file_wplus);
1594+
fs_File outFile = destFS.open(destFile, fs_file_write);
15951595
if(!outFile) {
15961596
log_e("[GZ ERROR] in gzExpander: cannot create destination file, no space left on device ?");
15971597
setError( ESP32_TARGZ_UZLIB_INVALID_FILE );

src/types/esp32_targz_types.h

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -70,11 +70,6 @@ typedef void (*genericLoggerCallback)( const char* format, ... ); // same behavi
7070
#define fs_SeekMode SeekMode
7171
#define fs_SeekSet SeekSet
7272

73-
#define fs_file_read FILE_READ
74-
#define fs_file_write FILE_WRITE
75-
#define fs_file_wplus FILE_WRITE_BEGIN
76-
77-
7873
#else
7974

8075
#ifndef FILE_READ
@@ -84,17 +79,15 @@ typedef void (*genericLoggerCallback)( const char* format, ... ); // same behavi
8479
#define FILE_WRITE "w+"
8580
#endif
8681

87-
#define fs_file_read FILE_READ
88-
#define fs_file_write FILE_WRITE
89-
#define fs_file_wplus FILE_WRITE_BEGIN
90-
9182
#define fs_FS fs::FS
9283
#define fs_File fs::File
9384
#define fs_SeekMode fs::SeekMode
9485
#define fs_SeekSet fs::SeekSet
9586

9687
#endif
9788

89+
#define fs_file_read FILE_READ
90+
#define fs_file_write FILE_WRITE
9891

9992

10093
// LibUnpacker types **************************************************************

0 commit comments

Comments
 (0)