From: Michael R Sweet Date: Thu, 20 Oct 2016 20:35:52 +0000 (-0400) Subject: Remove unnecessary logging. X-Git-Tag: v2.2.2~63 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c6a9dc36b7e2c3f9afe3680a301fcc86d3d40f75;p=thirdparty%2Fcups.git Remove unnecessary logging. Fix compiler warning for group ID comparisons. --- diff --git a/backend/usb-darwin.c b/backend/usb-darwin.c index 24693cd9dd..4f31d031a8 100644 --- a/backend/usb-darwin.c +++ b/backend/usb-darwin.c @@ -285,7 +285,6 @@ static void parse_options(char *options, char *serial, int serial_size, UInt32 * static void setup_cfLanguage(void); static void soft_reset(void); static void status_timer_cb(CFRunLoopTimerRef timer, void *info); -static void log_usb_class_driver(int is_64bit); #define IS_64BIT 1 #define IS_NOT_64BIT 0 @@ -471,11 +470,6 @@ print_device(const char *uri, /* I - Device URI */ return (CUPS_BACKEND_STOP); } -#ifdef __x86_64__ - if (status == noErr && driverBundlePath != NULL && CFStringCompare(driverBundlePath, kUSBGenericTOPrinterClassDriver, 0) != kCFCompareEqualTo) - log_usb_class_driver(IS_64BIT); -#endif /* __x86_64__ */ - if (driverBundlePath) CFRelease(driverBundlePath); @@ -2097,8 +2091,6 @@ static void run_legacy_backend(int argc, if (!usb_legacy_status) { - log_usb_class_driver(IS_NOT_64BIT); - /* * Setup a SIGTERM handler then block it before forking... */ @@ -2475,29 +2467,3 @@ static void get_device_id(cups_sc_status_t *status, *status = CUPS_SC_STATUS_OK; } - - -static void -log_usb_class_driver(int is_64bit) /* I - Is the USB class driver 64-bit? */ -{ - /* - * Report the usage of legacy USB class drivers to Apple if the user opts into providing - * feedback to Apple... - */ - - aslmsg aslm = asl_new(ASL_TYPE_MSG); - if (aslm) - { - ppd_file_t *ppd = ppdOpenFile(getenv("PPD")); - const char *make_model = ppd ? ppd->nickname : NULL; - ppd_attr_t *version = ppdFindAttr(ppd, "FileVersion", ""); - - asl_set(aslm, "com.apple.message.domain", "com.apple.printing.usb.64bit"); - asl_set(aslm, "com.apple.message.result", is_64bit ? "yes" : "no"); - asl_set(aslm, "com.apple.message.signature", make_model ? make_model : "Unknown"); - asl_set(aslm, "com.apple.message.signature2", version ? version->value : "?.?"); - asl_set(aslm, "com.apple.message.summarize", "YES"); - asl_log(NULL, aslm, ASL_LEVEL_NOTICE, ""); - asl_free(aslm); - } -} diff --git a/scheduler/auth.c b/scheduler/auth.c index a73a1e09da..6d573cc81f 100644 --- a/scheduler/auth.c +++ b/scheduler/auth.c @@ -1194,7 +1194,7 @@ cupsdCheckGroup( #endif /* __APPLE__ */ for (i = 0; i < ngroups; i ++) - if (group->gr_gid == groups[i]) + if ((int)group->gr_gid == (int)groups[i]) return (1); } #endif /* HAVE_GETGROUPLIST */