File tree Expand file tree Collapse file tree
src/nuclear/src/extension/network Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1818 matrix :
1919 os : [ubuntu-latest, windows-latest, macos-latest]
2020 # See supported Node.js release schedule at https://nodejs.org/en/about/releases/
21- node-version : [12 .x, 14.x, 16 .x]
21+ node-version : [18 .x, 20 .x]
2222
2323 steps :
24+ # Install node-gyp
25+ - name : Install node-gyp
26+ run : npm install -g node-gyp
2427 - uses : actions/checkout@v2
2528 - name : Use Node.js ${{ matrix.node-version }}
2629 uses : actions/setup-node@v2
Original file line number Diff line number Diff line change 2222#include < cerrno>
2323#include < cstring>
2424#include < set>
25+ #include < system_error>
2526#include < utility>
2627
2728#include " ../../util/network/get_interfaces.hpp"
@@ -171,9 +172,7 @@ namespace extension {
171172
172173 // Swap our address so the rest of the information is anys
173174 if (address.sock .sa_family == AF_INET ) { address.ipv4 .sin_addr .s_addr = htonl (INADDR_ANY ); }
174- else if (address.sock .sa_family == AF_INET6 ) {
175- address.ipv6 .sin6_addr = IN6ADDR_ANY_INIT ;
176- }
175+ else if (address.sock .sa_family == AF_INET6 ) { address.ipv6 .sin6_addr = IN6ADDR_ANY_INIT ; }
177176
178177 // Make our socket
179178 announce_fd = ::socket (address.sock .sa_family , SOCK_DGRAM , IPPROTO_UDP );
@@ -232,9 +231,7 @@ namespace extension {
232231 sizeof (ip_mreq));
233232
234233 if (status < 0 ) { last_network_errno = network_errno; }
235- else {
236- connected_count++;
237- }
234+ else { connected_count++; }
238235 }
239236 }
240237
@@ -552,15 +549,11 @@ namespace extension {
552549 ++it;
553550 }
554551 // Remove them from the list
555- else {
556- it = qit->second .targets .erase (it);
557- }
552+ else { it = qit->second .targets .erase (it); }
558553 }
559554
560555 if (qit->second .targets .empty ()) { qit = send_queue.erase (qit); }
561- else {
562- ++qit;
563- }
556+ else { ++qit; }
564557 }
565558 }
566559
@@ -647,9 +640,7 @@ namespace extension {
647640 }
648641 }
649642 // They're old but at least they're not timing out
650- else {
651- remote->last_update = std::chrono::steady_clock::now ();
652- }
643+ else { remote->last_update = std::chrono::steady_clock::now (); }
653644 } break ;
654645 case LEAVE : {
655646
You can’t perform that action at this time.
0 commit comments