zv2051 发表于 2013-05-25 15:45

linux_c_py_php 发表于 2013-05-25 16:06


       By default, getopt() permutes the contents of argv as it scans, so that eventually all the nonoptions are atthe
       end.   Two other modes are also implemented.If the first character of optstring is '+' or the environment vari-
       able POSIXLY_CORRECT is set, then option processing stops as soon as a nonoption argument is encountered.If the
       first character of optstring is '-', then each nonoption argv-element is handled as if it were the argument of an
       option with character code 1.(This is used by programs that were written to expect options and otherargv-ele-
       mentsinanyorderandthat care about the ordering of the two.)The special argument "--" forces an end of
       option-scanning regardless of the scanning mode.

zv2051 发表于 2013-05-25 17:29

页: [1]
查看完整版本: getopt_long函数参数问题