free the mem?
googled but google shows how to allocate mem.
ofcourse
When you do not need it anymore you must free the memory
Dont have to, if it wastes your important resource more than to release memory. OS will clear memory after your process terminate. (No one told me that fact before).
yeah but you need to make sure it is terminated
make sure it is leak detected then ;p
Do not mislead the people. Dynamic memory management should be handled by programmer. If leak occurs it is your fault. So, you must free memory that you allocated.
Thx i forgot how calloc works! I thought memset(, 0, ); frees mem 😁
memset sets a memory block to a specific value as the name implies 😃
Yeah i know, my problem was the value '\0'
Обсуждают сегодня