From: Serge E. Hallyn Date: Tue, 9 Aug 2011 14:51:01 +0000 (+0200) Subject: lxc-ps: support '-n name' and '-- ps-options' X-Git-Tag: lxc-0.7.5~11 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3729572b4b198c61642540afdf278244e2bd5f29;p=thirdparty%2Flxc.git lxc-ps: support '-n name' and '-- ps-options' This is more consistent with other lxc commands Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/lxc/+bug/820720 Signed-off-by: Daniel Lezcano --- diff --git a/src/lxc/lxc-ps.in b/src/lxc/lxc-ps.in index 7b3c8ab36..dd3b7fe39 100755 --- a/src/lxc/lxc-ps.in +++ b/src/lxc/lxc-ps.in @@ -134,7 +134,7 @@ sub display_headers { sub display_usage { print < \$arg_help, if ($arg_help) {display_help; exit 0;} if ($arg_usage) {display_usage; exit 0;} +if ($ARGV[0] == '--') { + shift @ARGV; +} + # Should we filter processes related to containers if ($arg_lxc) { $LXC_DISPLAY = 1;