亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? click-combine.cc

?? Click is a modular router toolkit. To use it you ll need to know how to compile and install the sof
?? CC
?? 第 1 頁 / 共 2 頁
字號:
/* * click-combine.cc -- combine several Click configurations at their devices * Eddie Kohler * * Copyright (c) 2000 Massachusetts Institute of Technology * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, subject to the conditions * listed in the Click LICENSE file. These conditions include: you must * preserve this copyright notice, and you cannot mention the copyright * holders in advertising related to the Software without their permission. * The Software is provided WITHOUT ANY WARRANTY, EXPRESS OR IMPLIED. This * notice is a summary of the Click LICENSE file; the license in that file is * legally binding. */#include <click/config.h>#include "routert.hh"#include "lexert.hh"#include <click/error.hh>#include <click/clp.h>#include "toolutils.hh"#include "elementmap.hh"#include <click/confparse.hh>#include <click/straccum.hh>#include <click/variableenv.hh>#include <click/driver.hh>#include <stdio.h>#include <stdlib.h>#include <string.h>#include <ctype.h>#include <errno.h>#include <time.h>#include <unistd.h>#include <sys/stat.h>#include <stdarg.h>#define HELP_OPT		300#define VERSION_OPT		301#define ROUTER_OPT		302#define OUTPUT_OPT		303#define NAME_OPT		304#define LINK_OPT		305#define EXPRESSION_OPT		306#define CONFIG_OPT		307static const Clp_Option options[] = {  { "config", 'c', CONFIG_OPT, 0, 0 },  { "expression", 'e', EXPRESSION_OPT, Clp_ValString, 0 },  { "file", 'f', ROUTER_OPT, Clp_ValString, 0 },  { "help", 0, HELP_OPT, 0, 0 },  { "link", 'l', LINK_OPT, Clp_ValString, 0 },  { "name", 'n', NAME_OPT, Clp_ValString, 0 },  { "output", 'o', OUTPUT_OPT, Clp_ValString, 0 },  { "version", 'v', VERSION_OPT, 0, 0 },};static const char *program_name;static String runclick_prog;voidshort_usage(){  fprintf(stderr, "Usage: %s [OPTION]... [ROUTERFILE]\n\Try '%s --help' for more information.\n",	  program_name, program_name);}voidusage(){  printf("\'Click-combine' combines several Click router configurations at their network\n\devices and writes the combined configuration to the standard output. The\n\combination is controlled by link specifications. The click-uncombine tool can\n\extract components from these combined configurations.\n\\n\Usage: %s [OPTION]... [ROUTERFILE | ROUTERNAME=FILE | LINKSPEC]\n\\n\Options:\n\  -o, --output FILE      Write combined configuration to FILE.\n\  -n, --name NAME        The next router component name is NAME.\n\  -f, --file FILE        Read router component configuration from FILE.\n\  -e, --expression EXPR  Use EXPR as router component configuration.\n\  -l, --link LINKSPEC    Add a link between router components. LINKSPEC has the\n\                         form 'NAME1.COMP1=NAME2.COMP2'. Each NAME is a router\n\                         component name. Each COMP is either an element name or\n\                         a device name (for linking at From/To/PollDevices).\n\  -c, --config           Output config only (not an archive).\n\      --help             Print this message and exit.\n\  -v, --version          Print version number and exit.\n\\n\Report bugs to <click@pdos.lcs.mit.edu>.\n", program_name);}static Vector<String> router_names;static Vector<RouterT *> routers;typedef PortT RouterPortT;	// except that 'port' is the router indexstatic Vector<RouterPortT> links_from;static Vector<RouterPortT> links_to;static Vector<int> link_id;static voidcc_read_router(String name, String &next_name, int &next_number,	       const char *filename, bool file_is_expr, ErrorHandler *errh){  if (name && next_name)    errh->warning("router name specified twice ('%s' and '%s')",		  next_name.c_str(), name.c_str());  else if (name)    next_name = name;  RouterT *r = read_router(filename, file_is_expr, errh);  if (r) {    r->flatten(errh);    if (next_name) {      int span = strspn(next_name.c_str(), "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz_/@0123456789");      if (span != next_name.length() || strstr(next_name.c_str(), "//") != 0	  || next_name[0] == '/' || next_name.back() == '/')	errh->error("router name '%s' is not a legal Click identifier", next_name.c_str());      router_names.push_back(next_name);    } else      router_names.push_back(String(next_number));    routers.push_back(r);  }  next_name = String();  next_number++;}static ElementT *try_find_device(String devname, String class1, String class2,		int rn, ErrorHandler *errh){  RouterT *r = routers[rn];  String router_name = router_names[rn];  // fix config  {    Vector<String> words;    cp_argvec(devname, words);    devname = words[0];  }  ElementClassT *t1 = ElementClassT::base_type(class1);  ElementClassT *t2 = ElementClassT::base_type(class2);  ElementT *found = 0;  bool duplicate = false;  for (int i = 0; i < r->nelements(); i++) {    ElementT *e = r->element(i);    if (e->live() && (e->type() == t1 || e->type() == t2)) {      Vector<String> words;      cp_argvec(e->configuration(), words);      if (words.size() >= 1 && words[0] == devname) {	// found it, but check for duplication	if (!found && !duplicate)	  found = e;	else if (!duplicate) {	  if (class2)	    errh->error("more than one '%s(%s)' or '%s(%s)' element in router '%s'", class1.c_str(), devname.c_str(), class2.c_str(), devname.c_str(), router_name.c_str());	  else	    errh->error("more than one '%s(%s)' element in router '%s'",			class1.c_str(), devname.c_str(), router_name.c_str());	  duplicate = true;	  found = 0;	}      }    }  }  return found;}static intparse_link(String text, ErrorHandler *errh){  // separate into words  Vector<String> words;  {    StringAccum sa;    const char *s = text.data();    for (int i = 0; i < text.length(); i++)      if (s[i] == '.' || s[i] == '=')	sa << ' ' << s[i] << ' ';      else	sa << s[i];    cp_spacevec(sa.take_string(), words);  }  // check for errors  if (words.size() != 7 || words[1] != "." || words[3] != "="      || words[5] != ".")    return errh->error("bad link definition '%s'", text.c_str());  // find pieces  int router1 = -1, router2 = -1;  for (int i = 0; i < routers.size(); i++) {    if (router_names[i] == words[0])      router1 = i;    if (router_names[i] == words[4])      router2 = i;  }  if (router1 < 0 || router2 < 0) {    if (router1 < 0) errh->error("no router named '%s'", words[0].c_str());    if (router2 < 0) errh->error("no router named '%s'", words[4].c_str());    return -1;  }  ElementT *element1 = routers[router1]->element(words[2]);  if (!element1)    element1 = try_find_device(words[2], "ToDevice", "", router1, errh);  ElementT *element2 = routers[router2]->element(words[6]);  if (!element2)    element2 = try_find_device(words[6], "FromDevice", "PollDevice", router2, errh);  if (!element1 || !element2) {    if (!element1)      errh->error("router '%s' has no element or device named '%s'", words[0].c_str(), words[2].c_str());    if (!element2)      errh->error("router '%s' has no element or device named '%s'", words[4].c_str(), words[6].c_str());    return -1;  }  // check element types  String tn1 = element1->type_name();  String tn2 = element2->type_name();  if (tn1 != "ToDevice") {    errh->warning("router '%s' element '%s' has unexpected class", words[0].c_str(), words[2].c_str());    errh->message("  expected ToDevice, got %s", tn1.c_str());  }  if (tn2 != "FromDevice" && tn2 != "PollDevice") {    errh->warning("router '%s' element '%s' has unexpected class", words[4].c_str(), words[6].c_str());    errh->message("  expected FromDevice or PollDevice, got %s", tn2.c_str());  }  // append link definition  links_from.push_back(RouterPortT(element1, router1));  links_to.push_back(RouterPortT(element2, router2));  return -1;}static voidfrob_nested_routerlink(ElementT *e){  String prefix = e->name().substring(e->name().begin(), find(e->name(), '/') + 1);  assert(prefix.length() > 1 && prefix.back() == '/');  Vector<String> words;  cp_argvec(e->configuration(), words);  for (int i = 0; i < words.size(); i += 2)    words[i] = prefix + words[i];  e->set_configuration(cp_unargvec(words));}static intcombine_links(ErrorHandler *errh){  // check for same name used as both source and destination  int before = errh->nerrors();  for (int i = 1; i < links_from.size(); i++)    for (int j = 0; j < i; j++)      if (links_from[i] == links_to[j] || links_from[j] == links_to[i]) {	const RouterPortT &h = links_from[i];	errh->error("router '%s' element '%s' used as both source and destination", router_names[h.port].c_str(), h.element->name_c_str());      }  if (errh->nerrors() != before)    return -1;  // combine links

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
91一区二区三区在线播放| 国产午夜精品久久久久久久| 欧美日韩二区三区| 久久久国产精华| 亚洲一卡二卡三卡四卡无卡久久 | 欧美日韩你懂得| www国产精品av| 午夜久久久影院| 99r精品视频| 久久综合av免费| 日本aⅴ免费视频一区二区三区| 成人av在线观| 久久免费电影网| 成人亚洲一区二区一| 国产精品一二三在| 91精品国产综合久久小美女 | 日韩免费高清电影| 洋洋av久久久久久久一区| 国产成人精品影视| 亚洲精品在线观| 老鸭窝一区二区久久精品| 欧美日韩一区二区不卡| 亚洲天堂免费在线观看视频| 国产精品资源网| 亚洲精品一区二区三区在线观看 | 中文字幕av资源一区| 免费欧美高清视频| 在线不卡免费欧美| 亚洲国产精品自拍| 欧美亚洲高清一区二区三区不卡| 国产精品久久久久久久久果冻传媒| 国产一区二区三区电影在线观看| 欧美一区日本一区韩国一区| 日本不卡视频在线观看| 亚洲综合小说图片| 久久精品国产成人一区二区三区| 亚洲欧美国产77777| 精品国产乱码久久久久久久 | 国产精品福利一区二区三区| 在线观看91视频| 成人激情免费网站| hitomi一区二区三区精品| 7799精品视频| 青青青伊人色综合久久| 欧美三级一区二区| 日韩av一级电影| 日韩一级片在线观看| 免费久久99精品国产| 欧美成人高清电影在线| 国产在线精品免费| 国产精品麻豆欧美日韩ww| 不卡免费追剧大全电视剧网站| 国产丝袜欧美中文另类| 懂色av中文字幕一区二区三区| 国产精品私房写真福利视频| 日韩午夜精品电影| 中文字幕在线播放不卡一区| 91亚洲精品久久久蜜桃| 亚洲一区在线视频| 7777精品伊人久久久大香线蕉的 | 欧美日韩视频专区在线播放| 午夜电影久久久| 亚洲精品一区二区三区香蕉| 高清在线不卡av| 一区二区三区毛片| 日韩欧美国产综合在线一区二区三区| 国产一区二区三区免费| 亚洲情趣在线观看| 欧美精品色综合| 成人黄色电影在线| 亚洲成在人线免费| 国产亚洲一区二区在线观看| 色域天天综合网| 久草精品在线观看| 亚洲欧美偷拍另类a∨色屁股| 欧美一区日韩一区| 99九九99九九九视频精品| 日日夜夜一区二区| 欧美一区二区三区在线视频| 综合电影一区二区三区 | 欧亚一区二区三区| 国产色91在线| 国产99一区视频免费| 欧美探花视频资源| 亚洲大型综合色站| caoporn国产精品| 国产精品三级电影| 91精品视频网| 国产精品福利在线播放| 51精品国自产在线| 97久久超碰国产精品| 九色porny丨国产精品| 亚洲精品视频一区二区| 国产欧美一区二区三区在线看蜜臀| 欧美少妇bbb| 99久久国产综合精品色伊 | 成人黄色国产精品网站大全在线免费观看| 亚洲一区电影777| 亚洲欧洲精品一区二区三区不卡| 日韩亚洲欧美综合| 欧美日韩电影在线播放| 99re这里只有精品6| 懂色av中文一区二区三区| 美国毛片一区二区| 日韩成人一级大片| 亚洲成人黄色影院| 香蕉影视欧美成人| 亚洲一区二区在线免费看| 中文字幕一区视频| 国产精品灌醉下药二区| 久久香蕉国产线看观看99| 欧美一区二区在线视频| 欧美日韩视频不卡| 欧美偷拍一区二区| 欧美天天综合网| 欧美吻胸吃奶大尺度电影| 日本韩国欧美一区| 91视频.com| 91激情在线视频| 欧美综合久久久| 欧美伊人精品成人久久综合97| 在线免费观看成人短视频| 色综合久久综合| 欧日韩精品视频| 欧美精品在线一区二区三区| 欧美亚洲动漫另类| 666欧美在线视频| 欧美一区二区视频在线观看2020| 欧美一区二区三区免费视频 | 久久夜色精品一区| 日韩欧美在线一区二区三区| 欧美精品丝袜中出| 在线国产电影不卡| 欧美在线你懂得| 91精品国产综合久久精品| 欧美色视频一区| 欧美色倩网站大全免费| 欧美综合久久久| 日本不卡在线视频| 韩国av一区二区| 国产成人免费视频网站| 国产乱子轮精品视频| 国产高清在线精品| 色诱亚洲精品久久久久久| 色哟哟在线观看一区二区三区| 色综合一个色综合| 欧美中文字幕一区二区三区亚洲| 一本大道久久a久久精二百| 欧美日韩亚洲不卡| 91精品国产91久久久久久一区二区| 欧美一区二区三区日韩视频| 日韩精品资源二区在线| 国产精品国产三级国产aⅴ无密码| 国产精品亲子乱子伦xxxx裸| 亚洲欧洲美洲综合色网| 一区二区在线看| 蜜臀av一级做a爰片久久| 国内不卡的二区三区中文字幕| 国产一区二区在线电影| www.欧美亚洲| 久久久精品欧美丰满| 欧美在线一区二区三区| 69堂精品视频| 日本一二三不卡| 亚洲成av人片一区二区梦乃| 美女视频第一区二区三区免费观看网站| 国产99精品国产| 欧美性做爰猛烈叫床潮| 日韩欧美国产综合| 1区2区3区国产精品| 狠狠色丁香久久婷婷综合_中| 99国产精品久久| 欧美精品高清视频| 国产丝袜美腿一区二区三区| 日韩国产一二三区| 国产91精品入口| 在线播放日韩导航| 久久久国际精品| 奇米色一区二区| 97精品久久久午夜一区二区三区| 欧美日韩激情在线| 欧美激情在线观看视频免费| 日韩电影免费一区| 91免费看片在线观看| 欧美mv和日韩mv的网站| 亚洲三级视频在线观看| 国产99精品国产| 欧美一区二区三区电影| 中文字幕在线不卡一区| 一区二区久久久久| caoporn国产一区二区| 欧美videofree性高清杂交| 国产精品日韩成人| 久久电影国产免费久久电影| 一本色道**综合亚洲精品蜜桃冫| 久久久久久一级片| 日韩黄色小视频| 成人毛片老司机大片| 国产精品三级电影| 99精品国产热久久91蜜凸|