summaryrefslogtreecommitdiff
path: root/src/main-utils.c
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2016-03-08 17:41:31 +0100
committerThomas Haller <thaller@redhat.com>2016-03-08 17:57:20 +0100
commitb36d7215255f2adb43341c15d438609d4087cc32 (patch)
tree93c703329adf232f7a983df981b34d79c50f1662 /src/main-utils.c
parent24d96e6f65cf29c76b462c37362190c54a4c0698 (diff)
downloadNetworkManager-b36d7215255f2adb43341c15d438609d4087cc32.tar.gz
all: drop str_if_set() in favor of the "?:" operator
str_if_set() was added to replace the non-standard gcc extension "?:". However, "?:" is supported by clang as well and we already use it at several places. Also, str_if_set() did not follow our naming scheme and renaming to nm_str_if_set() would be ugly. So just drop it.
Diffstat (limited to 'src/main-utils.c')
-rw-r--r--src/main-utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main-utils.c b/src/main-utils.c
index e0f254b752..7385e9c2a4 100644
--- a/src/main-utils.c
+++ b/src/main-utils.c
@@ -178,7 +178,7 @@ void
nm_main_utils_ensure_root ()
{
if (getuid () != 0) {
- fprintf (stderr, _("You must be root to run %s!\n"), str_if_set (g_get_prgname (), ""));
+ fprintf (stderr, _("You must be root to run %s!\n"), g_get_prgname () ?: "");
exit (1);
}
}