Revert renamings from 591877ee0c64958303dcbb4f2af3d343a420cf6a Pragmatically speaking, absent any good reason otherwise, naming conventions for functions like Sys_Error should remain consistent with Quake for developer sanity.
Work around Microsoft's broken vsnprintf implementation Microsoft's documentation says it has supported %zu (C99 standard format for size_t) for some years but trying to use it causes crashes at least on older versions of Windows. Makes dpsnprintf and dpvsnprintf documentation more accessible (these funcs have different return behaviour than the C standard ones). Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
sys: improve error and crash handling Renames Sys_Error to Sys_Abort (now using the Engine Abort message) for clarity (as distinct from the non-fatal Host_Error). Includes the engine version in the Crash and Abort SDL dialogs. Linux: includes the glibc backtrace in the Engine Crash SDL dialog. Fixes CTRL+C not working while the SDL dialog is open. Fixes a double Sys_Error/Sys_Abort when memory corruption was detected. Windows: omits colours when printing a Crash to stderr (not supported). Makes signal handling (mostly) POSIX async-signal-safe. Fixes a slight bug in PRVM_ShortStackTrace(). Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
PRVM: fix a use of strlcpy on an unterminated source This code is used when starting a QC program in a non-English language. See also 3727057b879ccfeaa434537f41a302f047e8cfae Also renames the dp_ustr2stp() parameter ssize to slen for clarity. Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
Misc data type and comment fixes Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
com_msg: optimise string and byte sequence reading Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
PRVM: optimise tempstring creation No need for strlen in PRVM_SetTempString(), usually we already have that information. Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
com: replace BSD strlcpy and strlcat Compared to BSD strlcpy and strlcat, dp_strlcpy and dp_strlcat are faster, never crash, and have a more useful return (DP didn't use the strlcpy return at all), see included docs. Adds dp_stpecpy() for efficient chain copying and dp_ustr2stp() for copying measured byte sequences (unterminated strings) to strings. Replaces the only use of the strlcat() return with dp_stpecpy(). Updates the forbidden string functions list. Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
com: rename BSD strlcpy and strlcat The C standard reserves str* and mem* for the implementation. Checking for BSD or OS X is not a robust way to determine if libc provides these (eg glibc may implement them). Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
common: Move com_game headers to new com_game.h
common: Move filematch headers to new filematch.h
common: Move infostring functions to new com_infostring.c
common: Update OpenBSD strlcpy and strlcat implementation
protocol/dp8: Implement parting messages * Extended CL_Disconnect and SV_DropClient for this purpose. * Add a string parameter to svc_disconnect and clc_disconnect, which shall contain the parting message.
protocol: Stub DP8 protocol
common: Use static_assert to prohibit unsafe functions more cleanly. Fixes compile warning with mingw builds
common: Define DP_STATIC_ASSERT which wraps static_assert
Remove redundant ampersand breaking ContainerOf and List_For_Each_Entry. Make all current loops use List_For_Each_Entry instead
Add/update license headers across various files
com_game: Add GAME_BATTLEMETAL https://store.steampowered.com/app/1447830/battleMETAL/ git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@13078 d7cf8633-e32d-0410-b094-e92efae38249