login -p -- 1 - BSD

This is a discussion on login -p -- 1 - BSD ; The subject line showed up in a ps -ax listing about 5 minutes ago. Since the -- option is not mentioned in man login, I tried to google, but the minus signs don't google well. What do the '--' and ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: login -p -- 1

  1. login -p -- 1

    The subject line showed up in a ps -ax listing about 5 minutes ago.
    Since the -- option is not mentioned in man login, I tried to google,
    but the minus signs don't google well. What do the '--' and the '1'
    arguments mean?

    Thanks,
    Dave Feustel

  2. Re: login -p -- 1

    dave writes:

    > The subject line showed up in a ps -ax listing about 5 minutes ago.
    > Since the -- option is not mentioned in man login, I tried to google,


    The "--" option is a somewhat standard part of option processing that
    says "I'm finished with options", the rest of the command line are
    non-option arguments. See getopt(3), the library function used by
    most software to process command line options, for more information.

    > but the minus signs don't google well. What do the '--' and the '1'
    > arguments mean?


    The login(1) man page says that the non-option argument is "user",
    so I'd expect it to be a user name. You'll need to find out what
    process invoked login to see why that process passed a user named 1.

    // marc

+ Reply to Thread