Ticket #224: ticket224.diff

File ticket224.diff, 1.4 KB (added by zhanglikun, 10 years ago)

The patch to enable xfrout can be launched in source code tree.

  • src/bin/auth/asio_link.cc

     
    6868dispatch_axfr_query(const int tcp_sock, char const axfr_query[],
    6969                    const uint16_t query_len)
    7070{
    71     string path(UNIX_SOCKET_FILE);
     71    string path;
     72    if (getenv("B10_FROM_BUILD")) {
     73        path = string(getenv("B10_FROM_BUILD")) + "/auth_xfrout_conn";
     74    } else {
     75        path = UNIX_SOCKET_FILE;
     76    }
     77   
    7278    XfroutClient xfr_client(path);
    7379    try {
    7480        xfr_client.connect();
  • src/bin/xfrout/xfrout.py.in

     
    4040
    4141if "B10_FROM_BUILD" in os.environ:
    4242    SPECFILE_PATH = os.environ["B10_FROM_BUILD"] + "/src/bin/xfrout"
     43    UNIX_SOCKET_FILE= os.environ["B10_FROM_BUILD"] + "/auth_xfrout_conn"
    4344else:
    4445    PREFIX = "@prefix@"
    4546    DATAROOTDIR = "@datarootdir@"
    4647    SPECFILE_PATH = "@datadir@/@PACKAGE@".replace("${datarootdir}", DATAROOTDIR).replace("${prefix}", PREFIX)
     48    UNIX_SOCKET_FILE = "@@LOCALSTATEDIR@@/auth_xfrout_conn"
     49
    4750SPECFILE_LOCATION = SPECFILE_PATH + "/xfrout.spec"
    48 UNIX_SOCKET_FILE = "@@LOCALSTATEDIR@@/auth_xfrout_conn"
    49 
    5051MAX_TRANSFERS_OUT = 10
    5152verbose_mode = False
    5253