Trim some redundant stuff from ftemaster.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@6174 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2022-01-28 10:48:21 +00:00
parent 0f5c092a96
commit 5fb58a8990
6 changed files with 20 additions and 9 deletions

View file

@ -776,8 +776,8 @@ static int Sys_EnumerateFiles2 (const char *truepath, int apathofs, const char *
return false;
}
}
else
Con_DPrintf("Stat failed for \"%s\"\n", file); //can happen with dead symlinks
// else
// Con_DPrintf("Stat failed for \"%s\"\n", file); //can happen with dead symlinks
}
}
} while(1);

View file

@ -124,6 +124,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#undef HUFFNETWORK
#undef SUPPORT_ICE
#undef WEBCLIENT
#undef MULTITHREAD
#undef LOADERTHREAD
#undef PACKAGEMANAGER
#undef PACKAGE_PK3
@ -133,6 +134,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#undef PACKAGE_DZIP
#undef AVAIL_XZDEC
#undef AVAIL_GZDEC
#undef SUBSERVERS
#undef HAVE_LEGACY
#undef IPLOG
#else
#if defined(SERVERONLY) && defined(CLIENTONLY)
#undef CLIENTONLY //impossible build. assume the config had CLIENTONLY and they tried building a dedicated server
@ -425,8 +429,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
//FIXME: HAVE_WINSSPI does not work as a server.
//FIXME: advertising dtls without a valid certificate will probably bug out if a client tries to auto-upgrade.
//FIXME: we don't cache server certs
#ifndef MASTERONLY
#define HAVE_DTLS
#endif
#endif
#if defined(USE_SQLITE) || defined(USE_MYSQL)
#define SQL

View file

@ -1131,7 +1131,7 @@ void MSG_WriteAngle (sizebuf_t *sb, float f)
Sys_Error("MSG_WriteAngle: undefined network primitive size");
}
#if defined(HAVE_CLIENT) || defined(HAVE_SERVER)
int MSG_ReadSize16 (sizebuf_t *sb)
{
unsigned short ssolid = MSG_ReadShort();
@ -1196,7 +1196,6 @@ int COM_EncodeSize(vec3_t mins, vec3_t maxs)
return solid;
}
#if defined(HAVE_CLIENT) || defined(HAVE_SERVER)
void MSG_WriteEntity(sizebuf_t *sb, unsigned int entnum)
{
if (entnum > MAX_EDICTS)
@ -6476,6 +6475,7 @@ char *VARGS va(const char *format, ...)
return string[bufnum];
}
#if defined(HAVE_CLIENT) || defined(HAVE_SERVER)
#ifdef NQPROT
//for compat with dpp7 protocols, or dp gamecode that neglects to properly precache particles.
void COM_Effectinfo_Enumerate(int (*cb)(const char *pname))
@ -6662,6 +6662,7 @@ unsigned int COM_RemapMapChecksum(model_t *model, unsigned int checksum)
#endif
return checksum;
}
#endif
static char Base64_Encode(int byt)
{

View file

@ -227,7 +227,7 @@ void Con_Log (const char *s)
}
#ifndef CLIENTONLY
#ifdef HAVE_SERVER
//still to add stuff at:
//connects
//disconnects

View file

@ -234,7 +234,7 @@ static int (VARGS *qgnutls_certificate_set_x509_key_mem)(gnutls_certificate_cre
static int (VARGS *qgnutls_certificate_get_x509_key)(gnutls_certificate_credentials_t res, unsigned index, gnutls_x509_privkey_t *key);
static void (VARGS *qgnutls_certificate_free_credentials)(gnutls_certificate_credentials_t sc);
#ifdef GNUTLS_DYNAMIC
#if defined(GNUTLS_DYNAMIC) && defined(HAVE_DTLS)
static int VARGS fallback_gnutls_set_default_priority_append(gnutls_session_t session, const char *add_prio, const char **err_pos, unsigned flags)
{
return qgnutls_set_default_priority(session);
@ -450,9 +450,11 @@ static qboolean Init_GNUTLS(void)
if (!hmod)
return false;
#ifdef HAVE_DTLS
qgnutls_set_default_priority_append = Sys_GetAddressForName(hmod, "gnutls_set_default_priority_append");
if (!qgnutls_set_default_priority_append)
qgnutls_set_default_priority_append = fallback_gnutls_set_default_priority_append;
#endif
#else
#define GNUTLS_FUNC(name) q##name = name;
#define GNUTLS_FUNCPTR(name) q##name = &name;
@ -760,6 +762,7 @@ static int QDECL SSL_CheckCert(gnutls_session_t session)
return GNUTLS_E_CERTIFICATE_ERROR;
}
#ifdef HAVE_DTLS
static int QDECL SSL_CheckFingerprint(gnutls_session_t session)
{ //actual certificate doesn't matter so long as it matches the hash we expect.
gnutlsfile_t *file = qgnutls_session_get_ptr (session);
@ -786,6 +789,7 @@ VFS_CLOSE(f);
Con_DPrintf(CON_ERROR "%s: rejecting certificate\n", file->certname);
return GNUTLS_E_CERTIFICATE_ERROR;
}
#endif
//return 1 to read data.
//-1 for error

View file

@ -1203,8 +1203,8 @@ static int Sys_EnumerateFiles2 (const char *truepath, int apathofs, const char *
}
else if (lstat(file, &st) == 0)
;//okay, so bad symlink, just mute it
else
fprintf(stderr, "Stat failed for \"%s\"\n", file);
// else
// fprintf(stderr, "Stat failed for \"%s\"\n", file);
}
}
} while(1);