mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-29 12:40:11 +01:00
platform: remove log_result from do_change_link()
It conveys no useful information beyond what
wait_for_nl_response_to_string() returns.
(cherry picked from commit ad659de3ba)
This commit is contained in:
parent
4591241d28
commit
c83740aaa7
1 changed files with 2 additions and 7 deletions
|
|
@ -7895,7 +7895,6 @@ do_change_link(NMPlatform *platform,
|
|||
char s_buf[256];
|
||||
int result = 0;
|
||||
NMLogLevel log_level = LOGL_DEBUG;
|
||||
const char *log_result = "failure";
|
||||
const char *log_detail = "";
|
||||
gs_free char *log_detail_free = NULL;
|
||||
const NMPObject *obj_cache;
|
||||
|
|
@ -7929,9 +7928,7 @@ retry:
|
|||
goto retry;
|
||||
}
|
||||
|
||||
if (seq_result == WAIT_FOR_NL_RESPONSE_RESULT_RESPONSE_OK) {
|
||||
log_result = "success";
|
||||
} else if (NM_IN_SET(seq_result, -EEXIST, -EADDRINUSE)) {
|
||||
if (NM_IN_SET(seq_result, WAIT_FOR_NL_RESPONSE_RESULT_RESPONSE_OK, -EEXIST, -EADDRINUSE)) {
|
||||
/* */
|
||||
} else if (NM_IN_SET(seq_result, -ESRCH, -ENOENT)) {
|
||||
log_detail = ", firmware not found";
|
||||
|
|
@ -7948,7 +7945,6 @@ retry:
|
|||
== 0) {
|
||||
/* work around ENFILE which may be wrongly returned (bgo #770456).
|
||||
* If the MAC address is as expected, assume success? */
|
||||
log_result = "success";
|
||||
log_detail = " (assume success changing address)";
|
||||
result = 0;
|
||||
} else if (NM_IN_SET(seq_result, -ENODEV)) {
|
||||
|
|
@ -7964,9 +7960,8 @@ retry:
|
|||
|
||||
out:
|
||||
_NMLOG(log_level,
|
||||
"do-change-link[%d]: %s changing link: %s%s",
|
||||
"do-change-link[%d]: %s%s",
|
||||
ifindex,
|
||||
log_result,
|
||||
wait_for_nl_response_to_string(seq_result, errmsg, s_buf, sizeof(s_buf)),
|
||||
log_detail);
|
||||
return result;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue