From: "cyx_mail@foxmail.com" <cyx_mail@foxmail.com>
To: linux-ppp@vger.kernel.org
Subject: Re: Re: about option_t
Date: Mon, 05 May 2008 12:43:02 +0000 [thread overview]
Message-ID: <200805052043009476581@foxmail.com> (raw)
In-Reply-To: <200805051534292917103@foxmail.com>
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="windows-1254", Size: 1536 bytes --]
thanks for you help!
2008-05-05
·¢¼þÈË£º James Carlson
·¢ËÍʱ¼ä£º 2008-05-05 19:41:21
ÊÕ¼þÈË£º cyx_mail@foxmail.com
³ËÍ£º linux-ppp
Ö÷Ì⣺ Re: about option_t
cyx_mail@foxmail.com writes:
> Which piece of code call the void *addr.
'addr' is a type-dependent value. It's not necessarily called as a
function -- that only happens if the type is o_special,
o_special_noarg, or o_wild.
> some plugins uses this pointer to call functions when the plugin loads. BTW, what is the exactly meaning of each value of enum opt_type struct? Thanks a lot!
The values should be relatively self-explanatory, if you read the code
in options.c or examine any of the code that uses the options.
o_special_noarg - option is processed by a function call and
consumes no other arguments.
o_special - option processed by function call and consumes one more
argument.
o_bool - option address is a 'bool' to be set to the lower 8 bits of
'flags'. If 'addr2' is set, use the OPT_A2{COPY,CLR,CLRB,OR) to
determine what is done to that value.
o_int - parse an integer, offset by low 8 bits of 'flags', and store
in 'addr'.
o_wild - special self-identifying option (no keyword; parsed by
appearance). Used only for IPv4 addresses, device name, and tty
speed.
--
__________ NOD32 3072 (20080503) Information __________
This message was checked by NOD32 antivirus system.
http://www.nod32cn.com
ÿôèº{.nÇ+·®+%Ëÿ±éݶ\x17¥wÿº{.nÇ+·¥{±þiþ)í
æèw*\x1fjg¬±¨\x1e¶Ý¢jÿ¾\a«þG«éÿ¢¸\f¢·¦j:+v¨wèjØm¶ÿþø\x1e¯ù\x1e®w¥þàþf£¢·hâúÿÙ¥
prev parent reply other threads:[~2008-05-05 12:43 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-05 7:34 about option_t cyx_mail
2008-05-05 10:05 ` James Cameron
2008-05-05 11:39 ` James Carlson
2008-05-05 12:43 ` cyx_mail [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200805052043009476581@foxmail.com \
--to=cyx_mail@foxmail.com \
--cc=linux-ppp@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.