mirror of
https://github.com/Motion-Project/motion.git
synced 2026-06-12 07:44:34 -04:00
Revise myfree method
This commit is contained in:
10
src/util.cpp
10
src/util.cpp
@@ -119,16 +119,6 @@ void myunquote(std::string &parm)
|
||||
|
||||
}
|
||||
|
||||
/* Free memory and set the pointer to NULL*/
|
||||
void myfree(void *ptr_addr) {
|
||||
void **ptr = (void **)ptr_addr;
|
||||
|
||||
if (*ptr != NULL) {
|
||||
free(*ptr);
|
||||
*ptr = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
/** mymalloc */
|
||||
void *mymalloc(size_t nbytes)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user