]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - cups/globals.c
Merge changes from CUPS 1.4svn-r8606.
[thirdparty/cups.git] / cups / globals.c
index 438bb029665cbaff72f09c8cf366a89652538cc2..e9e863313f00856616d6eb3f084e4dad113c0eed 100644 (file)
@@ -3,7 +3,7 @@
  *
  *   Global variable access routines for the Common UNIX Printing System (CUPS).
  *
- *   Copyright 2007-2008 by Apple Inc.
+ *   Copyright 2007-2009 by Apple Inc.
  *   Copyright 1997-2007 by Easy Software Products, all rights reserved.
  *
  *   These coded instructions, statements, and computer programs are the
@@ -112,7 +112,7 @@ _cupsGlobals(void)
     */
 
     globals->encryption  = (http_encryption_t)-1;
-    globals->password_cb = _cupsGetPassword;
+    globals->password_cb = (cups_password_cb2_t)_cupsGetPassword;
 
     cups_env_init(globals);
   }
@@ -144,6 +144,8 @@ static void
 globals_destructor(void *value)                /* I - Data to free */
 {
   int                  i;              /* Looping var */
+  _ipp_buffer_t                *buffer,        /* Current IPP read/write buffer */
+                       *next;          /* Next buffer */
   _cups_globals_t      *cg;            /* Global data */
 
 
@@ -159,6 +161,15 @@ globals_destructor(void *value)            /* I - Data to free */
 
   cupsFreeOptions(cg->cupsd_num_settings, cg->cupsd_settings);
 
+  for (buffer = cg->ipp_buffers; buffer; buffer = next)
+  {
+    next = buffer->next;
+    free(buffer);
+  }
+
+  cupsArrayDelete(cg->pwg_size_lut);
+  cupsArrayDelete(cg->leg_size_lut);
+
   free(value);
 }