comparison Resources/Patches/glog-ubuntu-18.04.diff @ 4686:d28eab3994f9 Orthanc-0.8.6

hotpatch to make Orthanc 0.8.6 compile on Ubuntu 18.04
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 09 Jun 2021 14:57:16 +0200
parents
children
comparison
equal deleted inserted replaced
4251:6784a119484d 4686:d28eab3994f9
1 diff -urEb glog-0.3.2.orig/src/demangle.cc glog-0.3.2/src/demangle.cc
2 --- glog-0.3.2.orig/src/demangle.cc 2021-06-09 14:45:34.648501148 +0200
3 +++ glog-0.3.2/src/demangle.cc 2021-06-09 14:46:07.376532698 +0200
4 @@ -167,7 +167,7 @@
5 // Returns true if "str" has at least "n" characters remaining.
6 static bool AtLeastNumCharsRemaining(const char *str, int n) {
7 for (int i = 0; i < n; ++i) {
8 - if (str == '\0') {
9 + if (str[i] == '\0') {
10 return false;
11 }
12 }
13 @@ -223,7 +223,7 @@
14 // Returns true and advances "mangled_cur" if we find any character in
15 // "char_class" at "mangled_cur" position.
16 static bool ParseCharClass(State *state, const char *char_class) {
17 - if (state->mangled_cur == '\0') {
18 + if (state->mangled_cur[0] == '\0') {
19 return false;
20 }
21 const char *p = char_class;