Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass compulsory mode argument to open when O_CREAT is used #3607

Merged
merged 1 commit into from
May 2, 2024

Conversation

teohhanhui
Copy link
Contributor

From man 2 open:

The mode argument must be supplied if O_CREAT or O_TMPFILE is
specified in flags; if it is not supplied, some arbitrary bytes
from the stack will be applied as the file mode.

(Fix broken build on Fedora Rawhide: https://download.copr.fedorainfracloud.org/results/teohhanhui/fex-emu/fedora-rawhide-aarch64/07399392-fex-emu/builder-live.log.gz)

From `man 2 open`:

> The mode argument must be supplied if O_CREAT or O_TMPFILE is
> specified in flags; if it is not supplied, some arbitrary bytes
> from the stack will be applied as the file mode.
Copy link
Member

@Sonicadvance1 Sonicadvance1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch! Thanks!

@Sonicadvance1 Sonicadvance1 merged commit f70aafb into FEX-Emu:main May 2, 2024
11 checks passed
@teohhanhui teohhanhui deleted the fix/open-mode branch May 2, 2024 20:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants