> -----Original Message----- > + uint8_t *rss_key; Instead of pointer can you just take key of type below, so u no need to do dynamic memory allocation using malloc and free . Ex: uint8_t hash_key[RSS_HASH_KEY_LENGTH]; And then do below ? rss_conf.rss_key = hash_key;