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

[BUG] crash on non writable directory #89

Closed
2 tasks done
nunotexbsd opened this issue Nov 3, 2022 · 1 comment · Fixed by #99
Closed
2 tasks done

[BUG] crash on non writable directory #89

nunotexbsd opened this issue Nov 3, 2022 · 1 comment · Fixed by #99
Labels
state: approved This issue or pull request was approved and can be worked on type: bug This fixes a bug. Increment the minor version

Comments

@nunotexbsd
Copy link
Contributor

General Information
Version: 0.5.1
Installation Method: source
Operating System: FreeBSD

Describe the bug
Crashes when running on directory not writable (without write permission, not owner)

To Reproduce

mkdir readonly
chmod =ro,+X readonly
cd readonly
wiki-tui

thread panicked while processing panic. aborting.
Abort

Expected behavior
Run normally

Screenshots
If applicable, add screenshots to help explain your problem.

Crash report (if available)

thread panicked while processing panic. aborting.
Abort

Additional context
I suspect it's related to trying to create wiki-tui.log.

Checklist

  • checked other issues for the same bug
  • read CONTRIBUTING.md
@nunotexbsd nunotexbsd added the bug label Nov 3, 2022
@Builditluc Builditluc linked a pull request Nov 4, 2022 that will close this issue
@Builditluc
Copy link
Owner

Builditluc commented Nov 4, 2022

Thank you for your bug report!
I've created and uploaded a patch that fixes the crash. Now, when wiki-tui cannot write the log file, it will print out this error message to stdout and continue running normally

wiki-tui/readonly🔒  bug/fix-cr
$  ../target/release/wiki-tui
Error: failed initializing the logger

Caused by:
    0: failed building the FileAppender
    1: Permission denied (os error 13)

@Builditluc Builditluc added state: approved This issue or pull request was approved and can be worked on type: bug This fixes a bug. Increment the minor version labels Dec 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
state: approved This issue or pull request was approved and can be worked on type: bug This fixes a bug. Increment the minor version
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants