Skip to content
This repository was archived by the owner on Jan 25, 2024. It is now read-only.
This repository was archived by the owner on Jan 25, 2024. It is now read-only.

session.CombinedOutput(cmd) returns wait: remote command exited without exit status or exit signal #11

@jbltx

Description

@jbltx

I have followed your project to create a SSH client and server and there's an interesting issue when I use session.CombinedOutput(cmd) to remotely execute a command, the call returns an error with the message panic: wait: remote command exited without exit status or exit signal.

The interesting part is if I actually try to connect to the server with another ssh client (like plink.exe), the stdoutput is well sent back to the client and no errors occur.

Maybe you will be able to know what is happening? I saw there's a Wait function for Session object and i'm not sure if it could resolve the problem. Or maybe it's a race condition between req.Reply(ok, nil) and channel.Close()?

The command tested was cmd /K dir . on Windows

Thank you

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions