+static G_CONST_RETURN gchar *pid_pathname(void)
+{
+static const gchar *static_pathname;
+static const char *user_val;
+
+ if (!static_pathname)
+ user_val=getenv("USER");
+ return pathname_find(&static_pathname,
+ G_STRINGIFY(LOCALSTATEDIR) "/run",PACKAGE ".pid",
+ (!user_val ? NULL : "/tmp"),
+ (!user_val ? NULL : udpgate_printf_alloca(".%s-%s.pid",user_val,PACKAGE)),
+ NULL);
+}
+
+