nuttx/arch
liang.huang 335aacbf1a arch/common: fix host_flags_to_mode() O_RDONLY sentinel collision
host_flags_to_mode() used a trailing 0 entry in modeflags[] as the
loop-termination sentinel. O_RDONLY is defined as 0 and is exactly
modeflags[1], so the loop's termination check fired before ever
comparing that entry, and a bare O_RDONLY open always fell through
to -EINVAL.

Bound the loop by array size (nitems()) instead of a value sentinel.

Signed-off-by: liang.huang <liang.huang@houmo.ai>
2026-08-03 20:58:21 +08:00
..
arm arch/common: fix host_flags_to_mode() O_RDONLY sentinel collision 2026-08-03 20:58:21 +08:00
arm64 arch/common: fix host_flags_to_mode() O_RDONLY sentinel collision 2026-08-03 20:58:21 +08:00
avr arch/avr/src/avrdx/avrdx_delay: add custom up_udelay function 2026-06-17 17:10:02 +08:00
ceva arch/ceva: Replace board_app_initialize 2026-05-02 18:36:46 +08:00
dummy
hc style: fix checkpatch issues after debug.h move 2026-04-07 07:50:06 -03:00
mips drivers: Fix comment typos — 'Pubic' → 'Public' across drivers and headers. 2026-07-04 02:00:24 +08:00
misoc include/debug.h: Move to include/nuttx/debug.h 2026-04-07 07:50:06 -03:00
or1k include/debug.h: Move to include/nuttx/debug.h 2026-04-07 07:50:06 -03:00
renesas drivers/efuse/efuse: Drivers Registered With World Write Permissions(Part 1) 2026-08-03 17:23:22 +08:00
risc-v arch/common: fix host_flags_to_mode() O_RDONLY sentinel collision 2026-08-03 20:58:21 +08:00
sim !include/fcntl.h: align open flags with Linux values 2026-07-03 10:33:47 +08:00
sparc drivers: Fix comment typos — 'Pubic' → 'Public' across drivers and headers. 2026-07-04 02:00:24 +08:00
tricore arch/tricore: Add hardware debug breakpoint and watchpoint support. 2026-05-22 15:38:36 +08:00
x86 drivers/efuse/efuse: Drivers Registered With World Write Permissions(Part 1) 2026-08-03 17:23:22 +08:00
x86_64 !include/fcntl.h: align open flags with Linux values 2026-07-03 10:33:47 +08:00
xtensa drivers/: Multiple Drivers Are Registered With World Writable - Part 2 2026-08-03 17:23:22 +08:00
z16 include/debug.h: Move to include/nuttx/debug.h 2026-04-07 07:50:06 -03:00
z80 style: fix checkpatch issues after debug.h move 2026-04-07 07:50:06 -03:00
CMakeLists.txt arch/z80: migrate to SPDX identifier 2024-12-02 17:23:25 +08:00
Kconfig sched/clock/clock_delay: added config flag to remove weak up_udelay 2026-06-17 17:10:02 +08:00