- int send_length;
- if (expiration)
- {
- send_length= snprintf(buffer, MEMCACHED_DEFAULT_COMMAND_SIZE,
- "flush_all %llu%s\r\n",
- (unsigned long long)expiration, no_reply ? " noreply" : "");
- }
- else
+ struct libmemcached_io_vector_st vector[]=
+ {
+ { memcached_literal_param("flush_all ") },
+ { buffer, send_length },
+ { " noreply", reply ? 0 : memcached_literal_param_size(" noreply") },
+ { memcached_literal_param("\r\n") }
+ };
+
+ memcached_return_t rc= MEMCACHED_SUCCESS;
+ for (uint32_t x= 0; x < memcached_server_count(ptr); x++)
+ {
+ memcached_server_write_instance_st instance= memcached_server_instance_fetch(ptr, x);
+
+ memcached_return_t rrc= memcached_vdo(instance, vector, 4, true);
+ if (rrc == MEMCACHED_SUCCESS and reply == true)