]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - cups/usersys.c
Merge changes from CUPS 1.5svn-r9763.
[thirdparty/cups.git] / cups / usersys.c
index 3b46d4cc8b81763176692195d86a5711cb3c8ff3..2013b74f5cda9d709429b9bd26477422bc119f7e 100644 (file)
@@ -31,6 +31,7 @@
  *   cupsSetUser()           - Set the default user name.
  *   cupsUser()              - Return the current user's name.
  *   _cupsGetPassword()      - Get a password from the user.
+ *   _cupsGSSServiceName()   - Get the GSS (Kerberos) service name.
  *   _cupsSetDefaults()      - Set the default server, port, and encryption.
  *   cups_read_client_conf() - Read a client.conf file.
  */
@@ -511,6 +512,25 @@ _cupsGetPassword(const char *prompt)       /* I - Prompt string */
 }
 
 
+#ifdef HAVE_GSSAPI
+/*
+ * '_cupsGSSServiceName()' - Get the GSS (Kerberos) service name.
+ */
+
+const char *
+_cupsGSSServiceName(void)
+{
+  _cups_globals_t *cg = _cupsGlobals();        /* Thread globals */
+
+
+  if (!cg->gss_service_name[0])
+    _cupsSetDefaults();
+
+  return (cg->gss_service_name);
+}
+#endif /* HAVE_GSSAPI */
+
+
 /*
  * '_cupsSetDefaults()' - Set the default server, port, and encryption.
  */