Fixed compile-time errors when using use_udp=0. Still some warnings but it builds.
This commit is contained in:
parent
1ba67c0d30
commit
78ad83a134
|
@ -467,6 +467,7 @@ int multi_objnum_is_past(objnum_t objnum)
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
|
(void)objnum;
|
||||||
Error("Protocol handling missing in multi_objnum_is_past\n");
|
Error("Protocol handling missing in multi_objnum_is_past\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -937,6 +938,7 @@ void multi_do_protocol_frame(int force, int listen)
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
|
(void)force; (void)listen;
|
||||||
Error("Protocol handling missing in multi_do_protocol_frame\n");
|
Error("Protocol handling missing in multi_do_protocol_frame\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1016,6 +1018,7 @@ void _multi_send_data(const ubyte *buf, unsigned len, int priority)
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
|
(void)buf; (void)len; (void)priority;
|
||||||
Error("Protocol handling missing in multi_send_data\n");
|
Error("Protocol handling missing in multi_send_data\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1035,6 +1038,7 @@ static void _multi_send_data_direct(const ubyte *buf, unsigned len, const player
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
|
(void)buf; (void)len; (void)priority;
|
||||||
Error("Protocol handling missing in multi_send_data_direct\n");
|
Error("Protocol handling missing in multi_send_data_direct\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1124,6 +1128,7 @@ int multi_endlevel(int *const secret)
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
|
(void)secret;
|
||||||
Error("Protocol handling missing in multi_endlevel\n");
|
Error("Protocol handling missing in multi_endlevel\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1302,6 +1307,7 @@ static void kick_player(player &plr, netplayer_info &nplr)
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
|
(void)nplr;
|
||||||
Error("Protocol handling missing in multi_send_message_end\n");
|
Error("Protocol handling missing in multi_send_message_end\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -141,12 +141,14 @@ template<typename E> E arg_enum(Arglist::iterator &pp, Arglist::const_iterator e
|
||||||
return static_cast<E>(arg_integer(pp, end));
|
return static_cast<E>(arg_integer(pp, end));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if DXX_USE_UDP
|
||||||
static void arg_port_number(Arglist::iterator &pp, Arglist::const_iterator end, uint16_t &out, bool allow_privileged)
|
static void arg_port_number(Arglist::iterator &pp, Arglist::const_iterator end, uint16_t &out, bool allow_privileged)
|
||||||
{
|
{
|
||||||
auto port = arg_integer(pp, end);
|
auto port = arg_integer(pp, end);
|
||||||
if (static_cast<uint16_t>(port) == port && (allow_privileged || port >= 1024))
|
if (static_cast<uint16_t>(port) == port && (allow_privileged || port >= 1024))
|
||||||
out = port;
|
out = port;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
static void InitGameArg()
|
static void InitGameArg()
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue