mirror of
https://github.com/SWG-Source/src.git
synced 2026-07-29 23:15:56 -04:00
this is probably the last of the fixes for the night
This commit is contained in:
+3
-3
@@ -47,9 +47,9 @@ if(WIN32)
|
||||
elseif(UNIX)
|
||||
find_package(Curses REQUIRED)
|
||||
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_DEBUG -DDEBUG_LEVEL=2 -DPRODUCTION=0 -g -pipe -Wall -O0")
|
||||
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -DDEBUG_LEVEL=0 -DPRODUCTION=1 -march=native -pipe -mtune=native -O2 ")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-format -Wno-unused-but-set-variable -Wno-write-strings -Wno-unknown-pragmas -Wno-uninitialized -Wno-reorder -std=c++11 -D_GLIBCXX_USE_CXX11_ABI=0")
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_DEBUG -DDEBUG_LEVEL=2 -DPRODUCTION=0 -g -pipe -O0 -Wall -Wno-overloaded-virtual -Wno-missing-braces -Wno-unused-private-field -Wno-format -Wno-unused-but-set-variable -Wno-write-strings -Wno-unknown-pragmas -Wno-uninitialized -Wno-reorder -Wno-unused-const-variable -Wno-unknown-warning-option")
|
||||
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -DDEBUG_LEVEL=0 -DPRODUCTION=1 -march=native -pipe -mtune=native -O2 -Wno-overloaded-virtual -Wno-missing-braces -Wno-unused-private-field -Wno-format -Wno-unused-but-set-variable -Wno-write-strings -Wno-unknown-pragmas -Wno-uninitialized -Wno-reorder -Wno-unused-const-variable -Wno-unknown-warning-option")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -D_GLIBCXX_USE_CXX11_ABI=0")
|
||||
|
||||
add_definitions(-DLINUX -D_REENTRANT -Dlinux -D_USING_STL -D__STL_NO_BAD_ALLOC -D_GNU_SOURCE -D_XOPEN_SOURCE=500)
|
||||
endif()
|
||||
|
||||
@@ -404,8 +404,9 @@ static bool dwarfSearch(char const *dwarfLines, unsigned int linesLength, void c
|
||||
char const *srcFile = bestUnderSrcFileTable+1;
|
||||
for (int i = 0; i < bestUnderSrcFileNum; ++i)
|
||||
{
|
||||
while (*srcFile++);
|
||||
while (*srcFile++) {
|
||||
srcFile += 3;
|
||||
}
|
||||
}
|
||||
retSrcFile = SymbolCache::uniqueString(srcFile);
|
||||
retSrcLine = bestUnderSrcLine;
|
||||
|
||||
@@ -461,7 +461,7 @@ void PixCounter::String::set(const char * format, ...)
|
||||
|
||||
char buffer[512];
|
||||
vsnprintf(buffer, sizeof(buffer), format, va);
|
||||
buffer[sizeof(buffer-1)] = '\0';
|
||||
buffer[sizeof(buffer)-1] = '\0';
|
||||
operator =(buffer);
|
||||
|
||||
va_end(va);
|
||||
|
||||
+1
-1
@@ -155,7 +155,7 @@ inline int UpperHashString(char *string)
|
||||
int h = 0;
|
||||
while (*string != 0)
|
||||
{
|
||||
h = ((31 * h) + (*string >= 'a' && *string <= 'z') ? (*string - 0x20) : *string) ^ (h >> 26);
|
||||
h = ((31 * h) + ((((*string >= 'a' && *string <= 'z') ? (*string - 0x20) : *string)) ^ (h >> 26)));
|
||||
string++;
|
||||
}
|
||||
return(h);
|
||||
|
||||
Reference in New Issue
Block a user