Change up strcasecmp/strncasecmp to be more C++y
This commit is contained in:
+5
-5
@@ -388,14 +388,14 @@ qsocket_t *NET_Connect(const char *host) {
|
||||
host = NULL;
|
||||
|
||||
if (host) {
|
||||
if (q_strcasecmp(host, "local") == 0) {
|
||||
if (std::is_eq(common::strcasecmp(host, "local"))) {
|
||||
numdrivers = 1;
|
||||
goto JustDoIt;
|
||||
}
|
||||
|
||||
if (hostCacheCount) {
|
||||
for (n = 0; n < hostCacheCount; n++)
|
||||
if (q_strcasecmp(host, hostcache[n].name) == 0) {
|
||||
if (std::is_eq(common::strcasecmp(host, hostcache[n].name))) {
|
||||
host = hostcache[n].cname;
|
||||
break;
|
||||
}
|
||||
@@ -419,7 +419,7 @@ qsocket_t *NET_Connect(const char *host) {
|
||||
|
||||
if (hostCacheCount) {
|
||||
for (n = 0; n < hostCacheCount; n++) {
|
||||
if (q_strcasecmp(host, hostcache[n].name) == 0) {
|
||||
if (std::is_eq(common::strcasecmp(host, hostcache[n].name))) {
|
||||
host = hostcache[n].cname;
|
||||
break;
|
||||
}
|
||||
@@ -690,8 +690,8 @@ void NET_Init(void) {
|
||||
port = common::check_param("-ipxport");
|
||||
|
||||
if (port.has_value()) {
|
||||
if (port < com_argc - 1)
|
||||
DEFAULTnet_hostport = std::atoi(com_argv[port.value() + 1]);
|
||||
if (port < common::_argv.size() - 1)
|
||||
DEFAULTnet_hostport = std::atoi(common::_argv[port.value() + 1].c_str());
|
||||
else
|
||||
Sys_Error("NET_Init: you must specify a number after -port");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user