I think you're on the right track with "comment = SWS '(' SWS *(ctext / quoted-pair / comment) SWS ')' ". Here are the two cases:
Retry-After = "Retry-After" HCOLON delta-seconds [ comment ] *(SEMI retry-param)
Server = "Server" HCOLON server-val *(LWS server-val)
server-val = product / comment
I looks like it would work for both. I remembered after I sent my last e-mail that in order to allow "Retry-After: 120 (I'm in a meeting)" we need "SWS "(" SWS".
If we are worried about white-space around text this still causes some issues. For "( Demo ( 5 days left ) )" the text would parse as "Demo ", "5 days left ", and " ". To fix this I was thinking we would have to use something like:
ctext-no-lws = %x21-27 / %x2A-5B / %x5D-7E / UTF8-NONASCII /
ctext-char = %x21-27 / %x2A-5B / %x5D-7E / UTF8-NONASCII / LWS /
ctext = ctext-no-lws [ *ctext-char ctext-no-lws ]
sub-comment = SWS '(' SWS *(ctext / sub-comment) SWS ')' SWS
comment = SWS '(' SWS *(ctext / sub-comment) SWS ')'
This production would parse the text in "( Demo ( 5 days left ) )" as "Demo" and "5 days left". I'm not sure how important removing white-space is in this field (it is just a comment).
Thanks,
Chris McKinnon
_______________________________________________ Sip-implementors mailing list [EMAIL PROTECTED] http://lists.cs.columbia.edu/mailman/listinfo/sip-implementors
