]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
msg: end parameter in entity_addr_t::parse is optional 13650/head
authorMykola Golub <mgolub@mirantis.com>
Sat, 25 Feb 2017 16:42:42 +0000 (17:42 +0100)
committerMykola Golub <mgolub@mirantis.com>
Sat, 25 Feb 2017 16:42:42 +0000 (17:42 +0100)
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
src/msg/msg_types.cc

index 1d118e9455c9983a68786f80010c04fdcd5afad5..67a699c9c4d247f877b96d42b2f34f77f8601601 100644 (file)
@@ -76,7 +76,9 @@ bool entity_addr_t::parse(const char *s, const char **end)
     newtype = TYPE_MSGR2;
   } else if (*s == '-') {
     *this = entity_addr_t();
-    *end = s + 1;
+    if (end) {
+      *end = s + 1;
+    }
     return true;
   }