#575088 screen -dm -c alternate-screenrc should report errors if something goes wrong

Package:
screen
Source:
screen
Description:
terminal multiplexer with VT100/ANSI terminal emulation
Submitter:
Date:
2026-05-18 12:25:02 UTC
Severity:
normal
Tags:
#575088#5
Date:
2010-03-23 12:07:09 UTC
From:
To:
How to reproduce

screen -dm -c alternate-screenrc
screen -r

fine that works
now do something stupid like

chown root:root alternate-screenrc
chmod 700 alternate-screenrc

and try again

screen -dm -c alternate-screenrc
screen -r
(Output) There is no screen to be resumed.

I think the first screen command should already give an error message (and a non zero exit code) not only the second.

It must have something todo with the -dm option since

screen -c alternate-screenrc
(Output) Unable to open "alternate-screenrc".

Gives at least a message that something went wrong. A non exit return code will still be on my wishlist.

Does it have something todo with 481411?

Best Regards,
  Torsten

#575088#10
Date:
2011-10-09 00:17:09 UTC
From:
To:
tag 575088 + confirmed upstream
kthxbye

Hi Torsten,

Torsten Neumann wrote:

I agree.

Nevertheless even screen without -dm does not return a non-zero exit
code in this situation either:

$ /usr/bin/screen -c /tmp/screenrc-bad
Unable to open "/tmp/screenrc-bad".
$ echo $?
0
$

I don't think so as #481411 has been fixed upstream and this problem
remains with the current HEAD.

		Regards, Axel