- if (ptr->flags & MEM_BINARY_PROTOCOL)
- return memcached_version_binary(ptr);
- else
- return memcached_version_textual(ptr);
+ if (ptr->flags.use_udp)
+ return MEMCACHED_NOT_SUPPORTED;
+
+ if (ptr->flags.binary_protocol)
+ return memcached_version_binary(ptr);
+ else
+ return memcached_version_textual(ptr);