Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion libraries/LittleFS/src/LittleFS.h
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,7 @@ class LittleFSFileImpl : public FileImpl {
}

int read(uint8_t* buf, size_t size) override {
if (!_opened || !_fd | !buf) {
if (!_opened || !_fd || !buf) {
return 0;
}
int result = lfs_file_read(_fs->getFS(), _getFD(), (void*) buf, size);
Expand Down
10 changes: 5 additions & 5 deletions libraries/SD/src/SD.h
Original file line number Diff line number Diff line change
Expand Up @@ -187,15 +187,15 @@ class SDClass {
}
const bool append = (mode & O_APPEND) > 0;

if (read & !write) {
if (read && !write) {
return "r";
} else if (!read & write & !append) {
} else if (!read && write && !append) {
return "w+";
} else if (!read & write & append) {
} else if (!read && write && append) {
return "a";
} else if (read & write & !append) {
} else if (read && write && !append) {
return "w+"; // may be a bug in FS::mode interpretation, "r+" seems proper
} else if (read & write & append) {
} else if (read && write && append) {
return "a+";
} else {
return "r";
Expand Down
2 changes: 1 addition & 1 deletion tools/platformio-build.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ def add_defines_from_platform_def(file):
"-Wl,--undefined=__pre_init_runtime_init_mutex",
"-Wl,--undefined=__pre_init_runtime_init_default_alarm_pool",
"-Wl,--undefined=__pre_init_first_per_core_initializer",
"-Wl,--undefined=__pre_init_runtime_init_per_core_bootrom_reset"
"-Wl,--undefined=__pre_init_runtime_init_per_core_bootrom_reset",
"-Wl,--undefined=__pre_init_runtime_init_per_core_h3_irq_registers",
"-Wl,--undefined=__pre_init_runtime_init_per_core_irq_priorities"
] + toolopts,
Expand Down
2 changes: 1 addition & 1 deletion tools/uf2conv.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ def get_drives():
try:
nul = open("nul:", "r")
r = subprocess.check_output(["powershell", "-NonInteractive", "-Command",
"Get-WmiObject -class Win32_LogicalDisk | "
"Get-WmiObject -class Win32_LogicalDisk | " +
"Format-Table -Property DeviceID, DriveType, Filesystem, VolumeName"],
stdin = nul)
nul.close()
Expand Down
Loading