Fix glibc 2.7 strtok_r() bug in a more permanent fashion.
[openvswitch] / lib / vconn-ssl.c
index 20bfb9793273c3f7eccc6ba61ed90ceece5a11f7..96890e6b3006bf708feb4bdfbbf2da7fb3b2444f 100644 (file)
@@ -279,12 +279,8 @@ ssl_open(const char *name, char *suffix, struct vconn **vconnp)
         return retval;
     }
 
-    /* Glibc 2.7 has a bug in strtok_r when compiling with optimization that
-     * can cause segfaults here:
-     * http://sources.redhat.com/bugzilla/show_bug.cgi?id=5614.
-     * Using "::" instead of the obvious ":" works around it. */
-    host_name = strtok_r(suffix, "::", &save_ptr);
-    port_string = strtok_r(NULL, "::", &save_ptr);
+    host_name = strtok_r(suffix, ":", &save_ptr);
+    port_string = strtok_r(NULL, ":", &save_ptr);
     if (!host_name) {
         ovs_error(0, "%s: bad peer name format", name);
         return EAFNOSUPPORT;