From: msweet Date: Tue, 21 Oct 2014 13:35:54 +0000 (+0000) Subject: Fix a DBUS crash if colord is not running (STR #4496) X-Git-Tag: v2.2b1~454 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cae3816ebe3458ea5453c162bea2d4068d3ce86c;p=thirdparty%2Fcups.git Fix a DBUS crash if colord is not running (STR #4496) git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@12225 a1ca3aef-8c08-0410-bb20-df032aa958be --- diff --git a/CHANGES-2.0.txt b/CHANGES-2.0.txt index a6ef2755cc..f78b0bbf5c 100644 --- a/CHANGES-2.0.txt +++ b/CHANGES-2.0.txt @@ -11,6 +11,8 @@ CHANGES IN CUPS V2.0.1 - The web interface now protects against frame "click-jacking" attacks (STR #4492) - Fixed a crash in ippAttributeString () + - Fixed a crash in the scheduler on Linux/*BSD if colord was not running + (STR #4496) - Added systemd support for cups-lpd (STR #4493) - The scheduler did not honor the FatalErrors directive for mis- configured Group and SystemGroup values (STR #4495) diff --git a/scheduler/colorman.c b/scheduler/colorman.c index 992ac2eff7..84437b207a 100644 --- a/scheduler/colorman.c +++ b/scheduler/colorman.c @@ -186,7 +186,8 @@ void cupsdStopColor(void) { #if !defined(__APPLE__) && defined(HAVE_DBUS) - dbus_connection_unref(colord_con); + if (colord_con) + dbus_connection_unref(colord_con); colord_con = NULL; #endif /* !__APPLE__ && HAVE_DBUS */ } diff --git a/xcode/CUPS.xcodeproj/project.pbxproj b/xcode/CUPS.xcodeproj/project.pbxproj index 908e485686..3ca5c990d0 100644 --- a/xcode/CUPS.xcodeproj/project.pbxproj +++ b/xcode/CUPS.xcodeproj/project.pbxproj @@ -2159,8 +2159,6 @@ 7226369C18AE6D19004ED309 /* org.cups.cupsd.plist */, 72E65BD718DC818400097E89 /* org.cups.cupsd.service.in */, 72E65BD818DC818400097E89 /* org.cups.cupsd.socket.in */, - 72D53A3615B4929D003F877F /* colorman.c */, - 72D53A3715B4929D003F877F /* colorman.h */, 72220F6913330B0C00FCA411 /* auth.c */, 72220F6A13330B0C00FCA411 /* auth.h */, 72220F6B13330B0C00FCA411 /* banners.c */, @@ -2171,6 +2169,8 @@ 72220F7013330B0C00FCA411 /* classes.h */, 72220F7113330B0C00FCA411 /* client.c */, 72220F7213330B0C00FCA411 /* client.h */, + 72D53A3615B4929D003F877F /* colorman.c */, + 72D53A3715B4929D003F877F /* colorman.h */, 72220F7313330B0C00FCA411 /* conf.c */, 72220F7413330B0C00FCA411 /* conf.h */, 72220F7513330B0C00FCA411 /* cupsd.h */,