哪位能够解释一下return的作用?
在帖子“PPPOE下HTB QOS 流量质量控制无效”中,有以下语句:/ ip firewall mangle
add chain=forward packet-size=32-512 action=mark-packet new-packet-mark=small passthrough=yes comment="" disabled=no
add chain=forward packet-size=32-512 action=return passthrough=yes comment="" disabled=no
add chain=forward packet-size=512-1200 action=mark-packet new-packet-mark=big passthrough=yes comment="" disabled=no
add chain=forward packet-size=512-1200 action=return passthrough=yes comment="" disabled=no
add chain=forward packet-size=1200-1500 action=mark-packet new-packet-mark=general passthrough=yes comment="" disabled=no
add chain=forward packet-size=1200-1500 action=return passthrough=yes comment="" disabled=no
对于return不了解,查说明书也没有答案,请哪位能够解释一下包含“return”语句的作用?
多谢! 跳出标记联结 return在手册中的解释是pass control back to the chain from where the jump took place,
在这里感觉没有什么作用呀?请指点。
[ 本帖最后由 tsingchina 于 2006-9-4 21:57 编辑 ] 你把英语翻译了就知道了
这个命令主要作用是当遇到符合条件的,就跳出同一CHAIN的链表,不再继续下面的命令了!这样就节约了时间,不用每条规则都判断,一旦符合这个规则,就跳出规则表! 非常感谢。
我错误地理解为循环执行了。
页:
[1]