1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

Merge branch '2.0release' into develop

This commit is contained in:
winlin 2016-09-01 16:51:18 +08:00
commit 7d96a33207
5 changed files with 12 additions and 10 deletions

View file

@ -564,13 +564,9 @@ int srs_st_init()
void srs_close_stfd(st_netfd_t& stfd)
{
if (stfd) {
int fd = st_netfd_fileno(stfd);
st_netfd_close(stfd);
stfd = NULL;
// st does not close it sometimes,
// close it manually.
close(fd);
// we must ensure the close is ok.
int err = st_netfd_close(stfd);
srs_assert(err != -1);
}
}