]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - scheduler/cupsd.h
Import CUPS 1.4svn r7023 into easysw/current.
[thirdparty/cups.git] / scheduler / cupsd.h
index ebaa350aa87517668e4ac227e667651c72763d91..a6340be4c10d03266d5e97de68545ea6334afd86 100644 (file)
@@ -1,25 +1,16 @@
 /*
- * "$Id$"
+ * "$Id: cupsd.h 6875 2007-08-27 23:25:06Z mike $"
  *
  *   Main header file for the Common UNIX Printing System (CUPS) scheduler.
  *
- *   Copyright 1997-2006 by Easy Software Products, all rights reserved.
+ *   Copyright 2007 by Apple Inc.
+ *   Copyright 1997-2007 by Easy Software Products, all rights reserved.
  *
  *   These coded instructions, statements, and computer programs are the
- *   property of Easy Software Products and are protected by Federal
- *   copyright law.  Distribution and use rights are outlined in the file
+ *   property of Apple Inc. and are protected by Federal copyright
+ *   law.  Distribution and use rights are outlined in the file "LICENSE.txt"
  *   "LICENSE" which should have been included with this file.  If this
- *   file is missing or damaged please contact Easy Software Products
- *   at:
- *
- *       Attn: CUPS Licensing Information
- *       Easy Software Products
- *       44141 Airport View Drive, Suite 204
- *       Hollywood, Maryland 20636 USA
- *
- *       Voice: (301) 373-9600
- *       EMail: cups-info@cups.org
- *         WWW: http://www.cups.org
+ *   file is missing or damaged, see the license at "http://www.cups.org/".
  */
 
 
@@ -150,24 +141,45 @@ extern const char *cups_hstrerror(int);
 #define RELOAD_CUPSD   2               /* Reload only cupsd.conf */
 
 
+/*
+ * Select callback function type...
+ */
+
+typedef void (*cupsd_selfunc_t)(void *data);
+
+
 /*
  * Globals...
  */
 
-VAR int                        MaxFDs,         /* Maximum number of files */
-                       SetSize;        /* The size of the input/output sets */
-VAR fd_set             *InputSet,      /* Input files for select() */
-                       *OutputSet;     /* Output files for select() */
+VAR int                        TestConfigFile  VALUE(0);
+                                       /* Test the cupsd.conf file? */
+VAR int                        MaxFDs;         /* Maximum number of files */
 
 VAR time_t             ReloadTime      VALUE(0);
                                        /* Time of reload request... */
 VAR int                        NeedReload      VALUE(RELOAD_ALL);
                                        /* Need to load configuration? */
+
+#ifdef HAVE_GSSAPI
+VAR krb5_context       KerberosContext;/* Kerberos context for credentials */
+#endif /* HAVE_GSSAPI */
+
 #ifdef HAVE_LAUNCH_H
 VAR int                        Launchd         VALUE(0);
                                        /* Running from launchd */
 #endif /* HAVE_LAUNCH_H */
 
+#if defined(__APPLE__) && defined(HAVE_DLFCN_H)
+typedef int (*PSQUpdateQuotaProcPtr)(const char *printer, const char *info, 
+                                     const char *user, int nPages, int options);
+VAR PSQUpdateQuotaProcPtr PSQUpdateQuotaProc
+                                       VALUE(0);
+                                       /* Apple PrintService quota function */
+#endif /* __APPLE__ && HAVE_DLFCN_H */
+
+
+
 
 /*
  * Prototypes...
@@ -200,9 +212,21 @@ extern int cupsdEndProcess(int pid, int force);
 extern const char *cupsdFinishProcess(int pid, char *name, int namelen);
 extern int     cupsdStartProcess(const char *command, char *argv[],
                                  char *envp[], int infd, int outfd,
-                                 int errfd, int backfd, int root, int *pid);
+                                 int errfd, int backfd, int sidefd,
+                                 int root, int *pid);
+
+extern int     cupsdAddSelect(int fd, cupsd_selfunc_t read_cb,
+                              cupsd_selfunc_t write_cb, void *data);
+extern int     cupsdDoSelect(long timeout);
+#ifdef CUPSD_IS_SELECTING
+extern int     cupsdIsSelecting(int fd);
+#endif /* CUPSD_IS_SELECTING */
+extern void    cupsdRemoveSelect(int fd);
+extern void    cupsdStartSelect(void);
+extern void    cupsdStopSelect(void);
 
+extern int     cupsdRemoveFile(const char *filename);
 
 /*
- * End of "$Id$".
+ * End of "$Id: cupsd.h 6875 2007-08-27 23:25:06Z mike $".
  */