File fix_compilation_sle11sp4.patch of Package rapidjson

Author: Adam Majer <adam.majer@suse.de>
Summary: Fix compilation with older GCC compiler
PR: https://github.com/miloyip/rapidjson/pull/755

include/rapidjson/reader.h:578: error: suggest a space before ';' or explicit braces around empty body in 'while' statement
: warnings being treated as errors

Index: rapidjson-1.1.0/include/rapidjson/reader.h
===================================================================
--- rapidjson-1.1.0.orig/include/rapidjson/reader.h
+++ rapidjson-1.1.0/include/rapidjson/reader.h
@@ -575,7 +575,7 @@ private:
                     }
                 }
                 else if (RAPIDJSON_LIKELY(Consume(is, '/')))
-                    while (is.Peek() != '\0' && is.Take() != '\n');
+                    while (is.Peek() != '\0' && is.Take() != '\n') {}
                 else
                     RAPIDJSON_PARSE_ERROR(kParseErrorUnspecificSyntaxError, is.Tell());
 
openSUSE Build Service is sponsored by