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

Fopen() and friends don't validate the mode #3058

Open
pmatilai opened this issue Apr 24, 2024 · 0 comments
Open

Fopen() and friends don't validate the mode #3058

pmatilai opened this issue Apr 24, 2024 · 0 comments
Labels
API API related bug

Comments

@pmatilai
Copy link
Member

This should fail instead of quietly falling back to fdio.

$ python -c "import rpm; print(rpm.fd('/dev/null', 'w', 'aaaiiiooo'))"
<rpm.fd object at 0x7f1490589bc0>

Besides being ugly buggy, it kinda prevents us from testing optional io types as well.

@pmatilai pmatilai added bug API API related labels Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API API related bug
Projects
Status: Todo
Development

No branches or pull requests

1 participant