diff options
| author | dimitri staessens <dimitri.staessens@ugent.be> | 2017-04-08 10:09:23 +0000 | 
|---|---|---|
| committer | Sander Vrijders <sander.vrijders@ugent.be> | 2017-04-08 10:09:23 +0000 | 
| commit | b796ca07a6068b8582b1f39b08eca3582e37dd4f (patch) | |
| tree | 3139645adfc4ebbdd087295bd686f7a25cf607c9 /src/ipcpd | |
| parent | a9aee05ef8a0d3a992f92c71fd8a3986d85d9135 (diff) | |
| parent | 23ffb733017a791ffec43b4031e0b64ce122153d (diff) | |
| download | ouroboros-b796ca07a6068b8582b1f39b08eca3582e37dd4f.tar.gz ouroboros-b796ca07a6068b8582b1f39b08eca3582e37dd4f.zip | |
Merged in dstaesse/ouroboros/be-query-timeo (pull request #473)
ipcpd: Fix wrong timeval value in LLC shim
Diffstat (limited to 'src/ipcpd')
| -rw-r--r-- | src/ipcpd/shim-eth-llc/main.c | 5 | 
1 files changed, 2 insertions, 3 deletions
| diff --git a/src/ipcpd/shim-eth-llc/main.c b/src/ipcpd/shim-eth-llc/main.c index 5789defa..27456eb7 100644 --- a/src/ipcpd/shim-eth-llc/main.c +++ b/src/ipcpd/shim-eth-llc/main.c @@ -766,7 +766,7 @@ static int eth_llc_ipcp_bootstrap(struct dif_config * conf)          int              skfd;      #endif  #else -        struct timeval   tv = {0, EVENT_WAIT_TIMEOUT * MILLION}; +        struct timeval   tv = {0, EVENT_WAIT_TIMEOUT * 1000};      #ifdef __FreeBSD__          struct ifaddrs * ifaddr;          struct ifaddrs * ifa; @@ -873,7 +873,6 @@ static int eth_llc_ipcp_bootstrap(struct dif_config * conf)          memcpy(eth_llc_data.device.sll_addr, ifr.ifr_hwaddr.sa_data, MAC_SIZE);          eth_llc_data.device.sll_halen    = MAC_SIZE;          eth_llc_data.device.sll_protocol = htons(ETH_P_ALL); -          eth_llc_data.s_fd = socket(AF_PACKET, SOCK_RAW, htons(ETH_P_802_2));          log_info("Using raw socket device."); @@ -893,7 +892,7 @@ static int eth_llc_ipcp_bootstrap(struct dif_config * conf)          if (setsockopt(eth_llc_data.s_fd, SOL_SOCKET, SO_RCVTIMEO,                         (void *) &tv, sizeof(tv))) { -                log_err("Failed to set socket timeout"); +                log_err("Failed to set socket timeout.");                  close(eth_llc_data.s_fd);                  return -1;          } | 
