Added detection for clang compiler and fixed various warnings triggered by it (bug 4878, r=dvander).
This commit is contained in:
+1
-1
@@ -410,7 +410,7 @@ size_t LibrarySystem::GetFileFromPath(char *buffer, size_t maxlength, const char
|
||||
size_t length = strlen(path);
|
||||
|
||||
for (size_t i = length - 1;
|
||||
i >= 0 && i <= length - 1;
|
||||
i <= length - 1;
|
||||
i--)
|
||||
{
|
||||
if (path[i] == '/'
|
||||
|
||||
@@ -872,7 +872,7 @@ bool TextParsers::ParseFile_INI(const char *file, ITextListener_INI *ini_listene
|
||||
ptr = save_ptr;
|
||||
|
||||
/* Lastly, strip ending whitespace off */
|
||||
for (size_t i=len-1; i>=0 && i<len; i--)
|
||||
for (size_t i=len-1; i<len; i--)
|
||||
{
|
||||
if (g_ws_chartable[(unsigned char)ptr[i]])
|
||||
{
|
||||
|
||||
@@ -37,7 +37,6 @@
|
||||
template <typename T>
|
||||
class FastLink
|
||||
{
|
||||
friend class iterator;
|
||||
public:
|
||||
struct FastLinkNode
|
||||
{
|
||||
|
||||
+1
-1
@@ -142,7 +142,7 @@ bool SourceModBase::InitializeSourceMod(char *error, size_t maxlength, bool late
|
||||
|
||||
/* Store name of game directory by itself */
|
||||
size_t len = strlen(gamepath);
|
||||
for (size_t i = len - 1; i >= 0; i--)
|
||||
for (size_t i = len - 1; i < len; i--)
|
||||
{
|
||||
if (gamepath[i] == PLATFORM_SEP_CHAR)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user