From: Monty Taylor Date: Fri, 2 Apr 2010 18:03:08 +0000 (-0700) Subject: Fixed the rest of the inline functions in .c files. X-Git-Tag: 0.40~17^2 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=83607be3d20de2cc96dd588bd418d0e407ffa726;p=awesomized%2Flibmemcached Fixed the rest of the inline functions in .c files. --- diff --git a/libmemcached/memcached.c b/libmemcached/memcached.c index 2d28830f..3a08b4a9 100644 --- a/libmemcached/memcached.c +++ b/libmemcached/memcached.c @@ -298,12 +298,12 @@ memcached_return_t memcached_push(memcached_st *destination, const memcached_st return memcached_server_push(destination, source->servers); } -inline memcached_server_write_instance_st memcached_server_instance_fetch(memcached_st *ptr, uint32_t server_key) +memcached_server_write_instance_st memcached_server_instance_fetch(memcached_st *ptr, uint32_t server_key) { return &ptr->servers[server_key]; } -inline memcached_server_instance_st memcached_server_instance_by_position(const memcached_st *ptr, uint32_t server_key) +memcached_server_instance_st memcached_server_instance_by_position(const memcached_st *ptr, uint32_t server_key) { return &ptr->servers[server_key]; } diff --git a/libmemcached/result.c b/libmemcached/result.c index 06e3ba9e..dae53bf7 100644 --- a/libmemcached/result.c +++ b/libmemcached/result.c @@ -95,44 +95,44 @@ memcached_return_t memcached_result_set_value(memcached_result_st *ptr, return memcached_string_append(&ptr->value, value, length); } -inline const char *memcached_result_key_value(const memcached_result_st *self) +const char *memcached_result_key_value(const memcached_result_st *self) { return self->key_length ? self->item_key : NULL; } -inline size_t memcached_result_key_length(const memcached_result_st *self) +size_t memcached_result_key_length(const memcached_result_st *self) { return self->key_length; } -inline const char *memcached_result_value(const memcached_result_st *self) +const char *memcached_result_value(const memcached_result_st *self) { const memcached_string_st *sptr= &self->value; return memcached_string_value(sptr); } -inline size_t memcached_result_length(const memcached_result_st *self) +size_t memcached_result_length(const memcached_result_st *self) { const memcached_string_st *sptr= &self->value; return memcached_string_length(sptr); } -inline uint32_t memcached_result_flags(const memcached_result_st *self) +uint32_t memcached_result_flags(const memcached_result_st *self) { return self->item_flags; } -inline uint64_t memcached_result_cas(const memcached_result_st *self) +uint64_t memcached_result_cas(const memcached_result_st *self) { return self->item_cas; } -inline void memcached_result_set_flags(memcached_result_st *self, uint32_t flags) +void memcached_result_set_flags(memcached_result_st *self, uint32_t flags) { self->item_flags= flags; } -inline void memcached_result_set_expiration(memcached_result_st *self, time_t expiration) +void memcached_result_set_expiration(memcached_result_st *self, time_t expiration) { self->item_expiration= expiration; } diff --git a/libmemcached/server.c b/libmemcached/server.c index f46c75bc..e7082af9 100644 --- a/libmemcached/server.c +++ b/libmemcached/server.c @@ -237,27 +237,27 @@ void memcached_server_list_free(memcached_server_list_st self) } } -inline uint32_t memcached_servers_set_count(memcached_server_st *servers, uint32_t count) +uint32_t memcached_servers_set_count(memcached_server_st *servers, uint32_t count) { return servers->number_of_hosts= count; } -inline uint32_t memcached_server_count(const memcached_st *self) +uint32_t memcached_server_count(const memcached_st *self) { return self->number_of_hosts; } -inline const char *memcached_server_name(memcached_server_instance_st self) +const char *memcached_server_name(memcached_server_instance_st self) { return self->hostname; } -inline in_port_t memcached_server_port(memcached_server_instance_st self) +in_port_t memcached_server_port(memcached_server_instance_st self) { return self->port; } -inline uint32_t memcached_server_response_count(memcached_server_instance_st self) +uint32_t memcached_server_response_count(memcached_server_instance_st self) { return self->cursor_active; } diff --git a/libmemcached/server_list.c b/libmemcached/server_list.c index 10b6a6b3..9287bc19 100644 --- a/libmemcached/server_list.c +++ b/libmemcached/server_list.c @@ -59,19 +59,19 @@ memcached_server_list_append(memcached_server_list_st ptr, return memcached_server_list_append_with_weight(ptr, hostname, port, 0, error); } -inline uint32_t memcached_server_list_count(const memcached_server_list_st self) +uint32_t memcached_server_list_count(const memcached_server_list_st self) { return (self == NULL) ? 0 : self->number_of_hosts; } -inline memcached_server_st *memcached_server_list(const memcached_st *self) +memcached_server_st *memcached_server_list(const memcached_st *self) { return self->servers; } -inline void memcached_server_list_set(memcached_st *self, memcached_server_st *list) +void memcached_server_list_set(memcached_st *self, memcached_server_st *list) { self->servers= list; } diff --git a/libmemcached/string.c b/libmemcached/string.c index b6943390..f708f8d4 100644 --- a/libmemcached/string.c +++ b/libmemcached/string.c @@ -177,27 +177,27 @@ memcached_return_t memcached_string_check(memcached_string_st *string, size_t ne return _string_check(string, need); } -inline size_t memcached_string_length(const memcached_string_st *self) +size_t memcached_string_length(const memcached_string_st *self) { return (size_t)(self->end - self->string); } -inline size_t memcached_string_size(const memcached_string_st *self) +size_t memcached_string_size(const memcached_string_st *self) { return self->current_size; } -inline const char *memcached_string_value(const memcached_string_st *self) +const char *memcached_string_value(const memcached_string_st *self) { return self->string; } -inline char *memcached_string_value_mutable(const memcached_string_st *self) +char *memcached_string_value_mutable(const memcached_string_st *self) { return self->string; } -inline void memcached_string_set_length(memcached_string_st *self, size_t length) +void memcached_string_set_length(memcached_string_st *self, size_t length) { self->end= self->string + length; }