diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2022-08-12 21:47:54 +0200 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2022-08-12 22:26:22 +0200 |
commit | 1929c1fcb2f305206c01a6fc79cd038d6d9615f5 (patch) | |
tree | fb57455266aeef7a4518facaac1aa50d26c0c3d4 /src/libsystemd-network/sd-dhcp6-lease.c | |
parent | Merge pull request #24138 from Keksgesicht/rfe/cryptenroll-keyfile (diff) | |
download | systemd-1929c1fcb2f305206c01a6fc79cd038d6d9615f5.tar.xz systemd-1929c1fcb2f305206c01a6fc79cd038d6d9615f5.zip |
dhcp6: gracefully handle NoBinding error
When we receive NoBinding status code, the requesting binding (address or
any other information) does not exist anymore in the server. Hence,
resending the request is meaningless. Let's restart the transaction from
the beginning in that case.
Diffstat (limited to 'src/libsystemd-network/sd-dhcp6-lease.c')
-rw-r--r-- | src/libsystemd-network/sd-dhcp6-lease.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsystemd-network/sd-dhcp6-lease.c b/src/libsystemd-network/sd-dhcp6-lease.c index f588514cb6..57c23965ed 100644 --- a/src/libsystemd-network/sd-dhcp6-lease.c +++ b/src/libsystemd-network/sd-dhcp6-lease.c @@ -512,7 +512,7 @@ static int dhcp6_lease_parse_message( return log_dhcp6_client_errno(client, r, "Failed to parse status code: %m"); if (r > 0) - return log_dhcp6_client_errno(client, SYNTHETIC_ERRNO(EINVAL), + return log_dhcp6_client_errno(client, dhcp6_message_status_to_errno(r), "Received %s message with non-zero status: %s%s%s", dhcp6_message_type_to_string(message->type), strempty(msg), isempty(msg) ? "" : ": ", |