diff --git a/lib/include/srslte/phy/utils/vector.h b/lib/include/srslte/phy/utils/vector.h index c8590a4f1..dbb0c977f 100644 --- a/lib/include/srslte/phy/utils/vector.h +++ b/lib/include/srslte/phy/utils/vector.h @@ -93,8 +93,8 @@ SRSLTE_API void* srslte_vec_realloc(void* ptr, uint32_t old_size, uint32_t new_s /* Zero memory */ SRSLTE_API void srslte_vec_cf_zero(cf_t* ptr, uint32_t nsamples); - SRSLTE_API void srslte_vec_f_zero(float* ptr, uint32_t nsamples); +SRSLTE_API void srslte_vec_u8_zero(uint8_t* ptr, uint32_t nsamples); /* print vectors */ SRSLTE_API void srslte_vec_fprint_c(FILE* stream, const cf_t* x, const uint32_t len); diff --git a/lib/src/phy/utils/vector.c b/lib/src/phy/utils/vector.c index 7727b2c39..283a34743 100644 --- a/lib/src/phy/utils/vector.c +++ b/lib/src/phy/utils/vector.c @@ -185,6 +185,11 @@ uint8_t* srslte_vec_u8_malloc(uint32_t nsamples) return (uint8_t*)srslte_vec_malloc((uint32_t)sizeof(uint8_t) * nsamples); } +void srslte_vec_u8_zero(uint8_t* ptr, uint32_t nsamples) +{ + memset(ptr, 0, sizeof(uint8_t) * nsamples); +} + void srslte_vec_cf_zero(cf_t* ptr, uint32_t nsamples) { memset(ptr, 0, sizeof(cf_t) * nsamples);