--- dao/ScsiIf-osx.cc.orig 2009-02-22 21:47:01.000000000 +1100
+++ dao/ScsiIf-osx.cc 2010-12-09 12:11:48.000000000 +1100
/* cdrdao specific includes and prototype */
#include "trackdb/util.h"
-extern void message(int level, const char *fmt, ...);
#include "decodeSense.cc"
/* Mac OS X specific includes */
@@ -120,7 +120,7 @@ int ScsiIf::init()
CFSTR(kIOPropertySCSITaskAuthoringDevice));
CFDictionarySetValue(dict, CFSTR(kIOPropertyMatchKey), sub);
IOServiceGetMatchingServices(kIOMasterPortDefault, dict, &iterator);
- if (!iterator) message(-2, "init: no iterator");
+ if (!iterator) log_message(-2, "init: no iterator");
@@ -134,16 +134,16 @@ int ScsiIf::init()
impl_->object_ = IORegistryEntryFromPath(kIOMasterPortDefault, impl_->path_);
/* Strange if (!x) ... if (x) style so you can #ifdef out the !x part */
- if (!impl_->object_) message(-2, "init: no object");
+ if (!impl_->object_) log_message(-2, "init: no object");
/* Get intermediate (IOCFPlugIn) plug-in for MMC device */
err = IOCreatePlugInInterfaceForService(impl_->object_,
kIOMMCDeviceUserClientTypeID, kIOCFPlugInInterfaceID,
&impl_->plugin_, &score);
- message(-2, "init: IOCreatePlugInInterfaceForService failed: %d", err);
+ log_message(-2, "init: IOCreatePlugInInterfaceForService failed: %d", err);
- if (!impl_->plugin_) message(-2, "init: no plugin");
+ if (!impl_->plugin_) log_message(-2, "init: no plugin");
/* Get the MMC interface (MMCDeviceInterface) */
herr = (*impl_->plugin_)->QueryInterface(impl_->plugin_,
@@ -154,29 +154,29 @@ int ScsiIf::init()
- message(-2, "init: QueryInterface failed: %d", herr);
+ log_message(-2, "init: QueryInterface failed: %d", herr);
- if (!impl_->mmc_) message(-2, "init: no mmc");
+ if (!impl_->mmc_) log_message(-2, "init: no mmc");
/* Get the SCSI interface */
impl_->scsi_ = (*impl_->mmc_)->GetSCSITaskDeviceInterface(impl_->mmc_);
- if (!impl_->scsi_) message(-2, "init: no scsi");
+ if (!impl_->scsi_) log_message(-2, "init: no scsi");
/* Obtain exclusive access to device */
err = (*impl_->scsi_)->ObtainExclusiveAccess(impl_->scsi_);
- message(-2, "init: ObtainExclusiveAccess failed: %d", err);
+ log_message(-2, "init: ObtainExclusiveAccess failed: %d", err);