Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • xfce4-screenshooter xfce4-screenshooter
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Graph
    • Compare revisions
  • Issues 15
    • Issues 15
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Artifacts
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Model experiments
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • AppsApps
  • xfce4-screenshooterxfce4-screenshooter
  • Issues
  • #84

Permissions on screenshot_dir cause screenshooter to get stuck in an infinite loop

Hello. I've stumbled onto a reproducible bug when copying my xfce config files to a second user. If a directory specified in screenshot_dir in ~/.config/xfce4/xfce4-screenshooter exists but is not wirtable or accessible to the user, then at the moment of pressing "Save" button the program gets stuck and consumes 100% of cpu.

A way to reproduce:

mkdir ~/test
chmod -x ~/test
set screenshot_dir=file:///home/<your username>/test/ in ~/.config/xfce4/xfce4-screenshooter

I've took a quick look into the source, the program is getting stuck inside https://gitlab.xfce.org/apps/xfce4-screenshooter/-/blob/master/lib/screenshooter-utils.c#L455 . The loop is never terminating.

Proposed solution is to add directory permission check in https://gitlab.xfce.org/apps/xfce4-screenshooter/-/blob/master/src/main.c#L242

Assignee
Assign to
Time tracking