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

FvwmCommand doesn't find socket #1034

Closed
akovalenko opened this issue Jun 10, 2024 · 3 comments · Fixed by #1037
Closed

FvwmCommand doesn't find socket #1034

akovalenko opened this issue Jun 10, 2024 · 3 comments · Fixed by #1037
Assignees
Labels
type:bug Something's broken!
Milestone

Comments

@akovalenko
Copy link

After commit da4387b, I started using FVWMMFL_SOCKET_PATH to put sockets into $XDG_RUNTIME_DIR/fvwm (which is the right place for multi-user system)

FvwmMFL (from the default config) creates a socket and provides FVWMMFL_SOCKET in the environment.

The problem is, FvwmCommand in da4387b doesn't take FVWMMFL_SOCKET into account, resorting to guessing the socket path from FVWMMFL_SOCKET_PATH and DISPLAY. On my system it happens to guess wrongly: when the socket is created, it uses DISPLAY=:1 (as received from .Xsession), but under fvwm3, I have DISPLAY=:1.0 (with screen number).

Upfront Information

  • Fvwm3 version (run: fvwm3 --version): fvwm3 1.1.1 (1.1.0-64-gf0366381)
    with support for: ReadLine, XPM, PNG, SVG, Shape, XShm, SM, Bidi text, XRandR, XRender, XCursor, XFT, NLS

  • Linux distribution or BSD name/version: Ubuntu jammy

  • Platform (run: uname -sp): Linux x86_64

Expected Behaviour

Launched XTerm from FVWM, started FvwmCommand Module FvwmConsole, expected to see the console

Actual Behaviour

Cannot find FvwmMFL socket /run/user/1000/fvwm/fvwm_mfl_:1.0.sock.
Please start FvwmMFL module from your fvwm configuration.

Steps to Reproduce

How can the problem be reproduced?

  • Have screenless DISPLAY=:n in your fvwm3's starting environment
  • Get DISPLAY=:n.0 in an XTerm launched by fvwm
  • See how FvwmCommand fails to guess the socket path
@akovalenko akovalenko added the type:bug Something's broken! label Jun 10, 2024
akovalenko added a commit to akovalenko/fvwm3 that referenced this issue Jun 10, 2024
Follow-up to da4387b FvwmMFL: introduce FVWMML_SOCKET_PATH for
namespacing. It breaks FvwmCommand for me because instead of taking
FVWMMFL_SOCKET from the environment, FvwmCommand guesses it from
FVWMMFL_SOCKET_PATH (incorrectly, DISPLAY=:1.0 while socket being
:1.sock)

When running FvwmCommand from a specific fvwm instance, FVWMMFL_SOCKET
is available, so let FvwmCommand use it. In the "outer" environment
where only FVWMML_SOCKET_PATH is available, let it resort to guessing
socket by $DISPLAY. Fixes fvwmorg#1034.
@ThomasAdam ThomasAdam added this to FVWM3 Jun 22, 2024
@github-project-automation github-project-automation bot moved this to To do in FVWM3 Jun 22, 2024
@ThomasAdam ThomasAdam added this to the 1.1.1 milestone Jun 22, 2024
@ThomasAdam ThomasAdam self-assigned this Jun 22, 2024
ThomasAdam added a commit that referenced this issue Jun 22, 2024
@ThomasAdam
Copy link
Member

Hi @akovalenko

Thanks. Can you please try FvwmCommand from the ta/fvwmmfl-display-socket3 branch?

This should now be working correctly.

@akovalenko
Copy link
Author

Hi @ThomasAdam, FvwmCommand from ta/fvwmmfl-display-socket3 works for me.

@ThomasAdam
Copy link
Member

Hey @akovalenko

Awesome. Thanks for testing!

@github-project-automation github-project-automation bot moved this from To do to Done in FVWM3 Jun 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something's broken!
Projects
Status: Done
2 participants