usnic: strengthen the check-if-accept()-failed test
This was Coverity CID 1269801.
Этот коммит содержится в:
родитель
117e6feaa1
Коммит
81585c0a7c
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2014 Cisco Systems, Inc. All rights reserved.
|
* Copyright (c) 2014-2015 Cisco Systems, Inc. All rights reserved.
|
||||||
* $COPYRIGHT$
|
* $COPYRIGHT$
|
||||||
*
|
*
|
||||||
* Additional copyrights may follow
|
* Additional copyrights may follow
|
||||||
@ -1003,7 +1003,7 @@ static void agent_thread_accept(int fd, short flags, void *context)
|
|||||||
|
|
||||||
len = sizeof(addr);
|
len = sizeof(addr);
|
||||||
int client_fd = accept(fd, &addr, &len);
|
int client_fd = accept(fd, &addr, &len);
|
||||||
if (-1 == client_fd) {
|
if (client_fd < 0) {
|
||||||
OPAL_ERROR_LOG(OPAL_ERR_IN_ERRNO);
|
OPAL_ERROR_LOG(OPAL_ERR_IN_ERRNO);
|
||||||
ABORT("accept() failed");
|
ABORT("accept() failed");
|
||||||
/* Will not return */
|
/* Will not return */
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user