From 27c87c75b80c2e42d806da832037e352ea152d10 Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Mon, 27 Apr 2015 15:41:33 +0200 Subject: [PATCH] platform: expose internal buffer for to_string() functions I'd like to reuse this buffer for other to-string functions that are platform related. (cherry picked from commit 655a0e71d485b46d385453370be2f6c6760461ce) --- src/platform/nm-platform.c | 2 +- src/platform/nm-platform.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/platform/nm-platform.c b/src/platform/nm-platform.c index de8f384206..34b72d196a 100644 --- a/src/platform/nm-platform.c +++ b/src/platform/nm-platform.c @@ -2632,7 +2632,7 @@ _lifetime_summary_to_string (gint32 now, guint32 timestamp, guint32 preferred, g return buf; } -static char _nm_platform_to_string_buffer[256]; +char _nm_platform_to_string_buffer[256]; const char * nm_platform_link_to_string (const NMPlatformLink *link) diff --git a/src/platform/nm-platform.h b/src/platform/nm-platform.h index 3a6c616839..23ded2a44b 100644 --- a/src/platform/nm-platform.h +++ b/src/platform/nm-platform.h @@ -315,6 +315,7 @@ typedef struct { extern const NMPlatformVTableRoute nm_platform_vtable_route_v4; extern const NMPlatformVTableRoute nm_platform_vtable_route_v6; +extern char _nm_platform_to_string_buffer[256]; typedef struct { int peer;