diff options
author | Thomas Haller <thaller@redhat.com> | 2014-06-09 10:27:48 +0200 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2014-06-19 22:26:10 +0200 |
commit | c6d45a408351097d714b3b5a3992937d60097cca (patch) | |
tree | 7263939885cdcf34f7a4bfa530646e7152a67f6e | |
parent | c29496125f32211e3337db3250aacc5a89e13325 (diff) | |
download | NetworkManager-c6d45a408351097d714b3b5a3992937d60097cca.tar.gz |
platform: modify address to_string() to show raw lifetime values
The "lifetime" part when printing an address in nm_platform_ip[46]_address_to_string()
is supposed to show the raw, internal values of the address.
We already have the "lft" and "pref" output that presents the expiries based on now.
These fields are already crafted to show what the user probably wants
to see when looking at debugging log. "lifetime" should not do any
special casing and just print the raw values.
Signed-off-by: Thomas Haller <thaller@redhat.com>
-rw-r--r-- | src/platform/nm-platform.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/src/platform/nm-platform.c b/src/platform/nm-platform.c index 17f452c547..e15de984f7 100644 --- a/src/platform/nm-platform.c +++ b/src/platform/nm-platform.c @@ -2107,12 +2107,6 @@ _lifetime_to_string (guint32 timestamp, guint32 lifetime, gint32 now, char *buf, static const char * _lifetime_summary_to_string (gint32 now, guint32 timestamp, guint32 preferred, guint32 lifetime, char *buf, size_t buf_size) { - if (timestamp == 0) { - if (preferred == NM_PLATFORM_LIFETIME_PERMANENT && lifetime == NM_PLATFORM_LIFETIME_PERMANENT) - return ""; - if (preferred == 0 && lifetime == 0) - return " lifetime unset"; - } g_snprintf (buf, buf_size, " lifetime %d-%u[%u,%u]", (signed) now, (unsigned) timestamp, (unsigned) preferred, (unsigned) lifetime); return buf; |