Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zabbix/zabbix.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorArtjoms Rimdjonoks <artjoms.rimdjonoks@zabbix.com>2022-03-23 16:49:24 +0300
committerArtjoms Rimdjonoks <artjoms.rimdjonoks@zabbix.com>2022-03-23 16:49:24 +0300
commite1ecab2bc85fae5b44628640fdf3ace56b603b38 (patch)
tree847654c012abbe6c0ecb72bac3926bd1e2ab68e8 /tests
parent84afcc2304b23dd10be577a21621990858a5d654 (diff)
.......... [DEV-2124] update libzbxshmem.a functions to mention sh in their names
Diffstat (limited to 'tests')
-rw-r--r--tests/libs/zbxdbcache/Makefile.am16
-rw-r--r--tests/mocks/valuecache/valuecache_mock.c24
-rw-r--r--tests/zbxmockdb.c2
3 files changed, 21 insertions, 21 deletions
diff --git a/tests/libs/zbxdbcache/Makefile.am b/tests/libs/zbxdbcache/Makefile.am
index 5bc04a1f716..fdb2877794d 100644
--- a/tests/libs/zbxdbcache/Makefile.am
+++ b/tests/libs/zbxdbcache/Makefile.am
@@ -83,12 +83,12 @@ CACHE_LIBS = \
COMMON_WRAP_FUNCS = \
-Wl,--wrap=zbx_mutex_create \
-Wl,--wrap=zbx_mutex_destroy \
- -Wl,--wrap=zbx_mem_create \
- -Wl,--wrap=zbx_mem_destroy \
- -Wl,--wrap=__zbx_mem_malloc \
- -Wl,--wrap=__zbx_mem_realloc \
- -Wl,--wrap=__zbx_mem_free \
- -Wl,--wrap=zbx_mem_dump_stats \
+ -Wl,--wrap=zbx_shmem_create \
+ -Wl,--wrap=zbx_shmem_destroy \
+ -Wl,--wrap=__zbx_shmem_malloc \
+ -Wl,--wrap=__zbx_shmem_realloc \
+ -Wl,--wrap=__zbx_shmem_free \
+ -Wl,--wrap=zbx_shmem_dump_stats \
-Wl,--wrap=zbx_history_get_values \
-Wl,--wrap=zbx_history_add_values \
-Wl,--wrap=zbx_history_sql_init \
@@ -176,10 +176,10 @@ dc_expand_user_macros_in_func_params_CFLAGS = \
-I@top_srcdir@/tests/mocks/configcache \
-I@top_srcdir@/src/libs/zbxdbcache
dc_expand_user_macros_in_func_params_SOURCES = \
- dc_expand_user_macros_in_func_params.c
+ dc_expand_user_macros_in_func_params.c
dc_expand_user_macros_in_func_params_LDADD = \
$(top_srcdir)/tests/mocks/configcache/libconfigcachemock.a \
- $(CACHE_LIBS) @SERVER_LIBS@
+ $(CACHE_LIBS) @SERVER_LIBS@
dc_expand_user_macros_in_func_params_LDFLAGS = @SERVER_LDFLAGS@ \
-Wl,--wrap=zbx_hashset_search
diff --git a/tests/mocks/valuecache/valuecache_mock.c b/tests/mocks/valuecache/valuecache_mock.c
index 0453edf4a1b..455a7804211 100644
--- a/tests/mocks/valuecache/valuecache_mock.c
+++ b/tests/mocks/valuecache/valuecache_mock.c
@@ -43,13 +43,13 @@ static zbx_timespec_t vcmock_ts;
int __wrap_zbx_mutex_create(zbx_mutex_t *mutex, zbx_mutex_name_t name, char **error);
void __wrap_zbx_mutex_destroy(zbx_mutex_t *mutex);
-int __wrap_zbx_mem_create(zbx_mem_info_t **info, zbx_uint64_t size, const char *descr, const char *param,
+int __wrap_zbx_shmem_create(zbx_mem_info_t **info, zbx_uint64_t size, const char *descr, const char *param,
int allow_oom, char **error);
-void __wrap_zbx_mem_destroy(zbx_mem_info_t *info);
-void *__wrap___zbx_mem_malloc(const char *file, int line, zbx_mem_info_t *info, const void *old, size_t size);
-void *__wrap___zbx_mem_realloc(const char *file, int line, zbx_mem_info_t *info, void *old, size_t size);
-void __wrap___zbx_mem_free(const char *file, int line, zbx_mem_info_t *info, void *ptr);
-void __wrap_zbx_mem_dump_stats(int level, zbx_mem_info_t *info);
+void __wrap_zbx_shmem_destroy(zbx_mem_info_t *info);
+void *__wrap___zbx_shmem_malloc(const char *file, int line, zbx_mem_info_t *info, const void *old, size_t size);
+void *__wrap___zbx_shmem_realloc(const char *file, int line, zbx_mem_info_t *info, void *old, size_t size);
+void __wrap___zbx_shmem_free(const char *file, int line, zbx_mem_info_t *info, void *ptr);
+void __wrap_zbx_shmem_dump_stats(int level, zbx_mem_info_t *info);
int __wrap_zbx_history_get_values(zbx_uint64_t itemid, int value_type, int start, int count, int end,
zbx_vector_history_record_t *values);
int __wrap_zbx_history_add_values(const zbx_vector_ptr_t *history);
@@ -497,7 +497,7 @@ void __wrap_zbx_mutex_destroy(zbx_mutex_t *mutex)
zbx_mock_assert_ptr_eq("Attempting to destroy unknown mutex", vc_mutex, mutex);
}
-int __wrap_zbx_mem_create(zbx_mem_info_t **info, zbx_uint64_t size, const char *descr, const char *param,
+int __wrap_zbx_shmem_create(zbx_mem_info_t **info, zbx_uint64_t size, const char *descr, const char *param,
int allow_oom, char **error)
{
*info = vc_meminfo;
@@ -510,12 +510,12 @@ int __wrap_zbx_mem_create(zbx_mem_info_t **info, zbx_uint64_t size, const char *
return SUCCEED;
}
-void __wrap_zbx_mem_destroy(zbx_mem_info_t *info)
+void __wrap_zbx_shmem_destroy(zbx_mem_info_t *info)
{
zbx_free(info);
}
-void *__wrap___zbx_mem_malloc(const char *file, int line, zbx_mem_info_t *info, const void *old, size_t size)
+void *__wrap___zbx_shmem_malloc(const char *file, int line, zbx_mem_info_t *info, const void *old, size_t size)
{
size_t *psize;
@@ -535,7 +535,7 @@ void *__wrap___zbx_mem_malloc(const char *file, int line, zbx_mem_info_t *info,
return (void *)(psize + 1);
}
-void *__wrap___zbx_mem_realloc(const char *file, int line, zbx_mem_info_t *info, void *old, size_t size)
+void *__wrap___zbx_shmem_realloc(const char *file, int line, zbx_mem_info_t *info, void *old, size_t size)
{
size_t *psize;
@@ -556,7 +556,7 @@ void *__wrap___zbx_mem_realloc(const char *file, int line, zbx_mem_info_t *info,
return (void *)(psize + 1);
}
-void __wrap___zbx_mem_free(const char *file, int line, zbx_mem_info_t *info, void *ptr)
+void __wrap___zbx_shmem_free(const char *file, int line, zbx_mem_info_t *info, void *ptr)
{
size_t *psize;
@@ -575,7 +575,7 @@ void __wrap___zbx_mem_free(const char *file, int line, zbx_mem_info_t *info, voi
zbx_free(psize);
}
-void __wrap_zbx_mem_dump_stats(int level, zbx_mem_info_t *info)
+void __wrap_zbx_shmem_dump_stats(int level, zbx_mem_info_t *info)
{
ZBX_UNUSED(level);
ZBX_UNUSED(info);
diff --git a/tests/zbxmockdb.c b/tests/zbxmockdb.c
index 4a5cd3893cc..15c642e1c32 100644
--- a/tests/zbxmockdb.c
+++ b/tests/zbxmockdb.c
@@ -295,7 +295,7 @@ int __wrap_DBcommit(void)
void zbx_mockdb_init(void)
{
zbx_hashset_create_ext(&mockdb.queries, 0, mockdb_query_hash, mockdb_query_compare, mockdb_query_clear,
- ZBX_DEFAULT_MEM_MALLOC_FUNC, ZBX_DEFAULT_MEM_REALLOC_FUNC, ZBX_DEFAULT_MEM_FREE_FUNC);
+ ZBX_DEFAULT_SHMEM_MALLOC_FUNC, ZBX_DEFAULT_SHMEM_REALLOC_FUNC, ZBX_DEFAULT_SHMEM_FREE_FUNC);
}
void zbx_mockdb_destroy(void)