forked from lei.chen/myxce
update controller code
This commit is contained in:
parent
2836d196da
commit
41f56fa6ed
54 changed files with 9688 additions and 214 deletions
|
|
@ -309,14 +309,15 @@ int objmgr_set_default(objmgr_t* mgr)
|
|||
return 0;
|
||||
}
|
||||
|
||||
myobj_t *obj_alloc(size_t size) {
|
||||
myobj_t *obj;
|
||||
|
||||
myobj_t* obj_alloc(size_t size)
|
||||
{
|
||||
myobj_t* obj;
|
||||
|
||||
if (size <= 0) {
|
||||
SET_ERROR(EINVAL);
|
||||
return NULL;
|
||||
SET_ERROR(EINVAL);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
obj = (myobj_t *)calloc(1, sizeof(*obj) + size);
|
||||
obj = (myobj_t*)calloc(1, sizeof(*obj) + size);
|
||||
return obj;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue