MCPcopy Create free account
hub / github.com/data61/MP-SPDZ / get_name

Method get_name

Networking/Server.cpp:39–54  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

37
38
39void Server::get_name(int num)
40{
41 if (OnlineOptions::singleton.has_option("debug_networking"))
42 cerr << "Player " << num << " started." << endl;
43
44 // Receive name sent by client (legacy) - not used here
45 octetStream os;
46 os.Receive(socket_num[num]);
47 receive(socket_num[num],(octet*)&ports[num],4);
48 if (OnlineOptions::singleton.has_option("debug_networking"))
49 cerr << "Player " << num << " listening on " << os.str() << ":"
50 << ports[num] << endl;
51
52 // Get client IP
53 get_ip(num);
54}
55
56
57void Server::send_names()

Callers 1

executeMethod · 0.45

Calls 4

has_optionMethod · 0.80
receiveFunction · 0.70
ReceiveMethod · 0.45
strMethod · 0.45

Tested by

no test coverage detected