mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-08 19:08:14 +00:00
formatting fixes (bug #4739)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6158 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
8
io.c
8
io.c
@@ -66,7 +66,6 @@ struct io_context {
|
||||
int needshrink;
|
||||
};
|
||||
|
||||
|
||||
struct io_context *io_context_create(void)
|
||||
{
|
||||
/* Create an I/O context */
|
||||
@@ -88,10 +87,11 @@ struct io_context *io_context_create(void)
|
||||
free(tmp->fds);
|
||||
free(tmp);
|
||||
tmp = NULL;
|
||||
} else
|
||||
} else {
|
||||
memset(tmp->ior, 0, (GROW_SHRINK_SIZE / 2) * sizeof(struct io_rec));
|
||||
}
|
||||
}
|
||||
}
|
||||
return tmp;
|
||||
}
|
||||
|
||||
@@ -130,7 +130,6 @@ static int io_grow(struct io_context *ioc)
|
||||
ioc->maxfdcnt -= GROW_SHRINK_SIZE;
|
||||
return -1;
|
||||
}
|
||||
|
||||
} else {
|
||||
/*
|
||||
* Out of memory. We return to the old size, and return a failure
|
||||
@@ -190,7 +189,8 @@ int *ast_io_change(struct io_context *ioc, int *id, int fd, ast_io_cb callback,
|
||||
if (data)
|
||||
ioc->ior[*id].data = data;
|
||||
return id;
|
||||
} else return NULL;
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static int io_shrink(struct io_context *ioc)
|
||||
|
||||
Reference in New Issue
Block a user