Changeset 408 for trunk/Cocoa/F-Script Anywhere/Source
- Timestamp:
- 02/24/08 10:06:18 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Cocoa/F-Script Anywhere/Source/SCPatch/SCPatchController/SCPatchLoader.c
r342 r408 11 11 #undef USE_CFRUNLOOP 12 12 #undef CHECK_SYMBOL_REFERENCES 13 # undefSCPL_DEBUG_LOG13 #define SCPL_DEBUG_LOG 14 14 15 15 #ifdef SCPL_DEBUG_LOG … … 32 32 33 33 34 syslog(LOG_ALERT, "SCPL: sending notification of patch loading error %x\n", err); 34 35 if((clientBundleID = CFStringCreateWithCharacters(NULL, uniBundleID->unicode, uniBundleID->length)) != NULL && 35 36 (controllerBundleID = CFStringCreateWithCharacters(NULL, uniControllerBundleID->unicode, uniControllerBundleID->length)) != NULL && … … 127 128 NSSymbol symbol; 128 129 129 if(NSCreateObjectFileImageFromFile(urlData, &image) == NSObjectFileImageSuccess && CanLoadImage(image) && 130 (module = NSLinkModule(image, urlData, NSLINKMODULE_OPTION_BINDNOW | NSLINKMODULE_OPTION_PRIVATE | NSLINKMODULE_OPTION_RETURN_ON_ERROR)) != NULL) 131 { 130 if(NSCreateObjectFileImageFromFile(urlData, &image) != NSObjectFileImageSuccess || !CanLoadImage(image)) 131 { 132 err = err_couldnt_load_injection_bundle; 133 } 134 else if((module = NSLinkModule(image, urlData, NSLINKMODULE_OPTION_BINDNOW | NSLINKMODULE_OPTION_PRIVATE | NSLINKMODULE_OPTION_RETURN_ON_ERROR)) != NULL) 135 { 132 136 if((symbol = NSLookupSymbolInModule(module, "_SCPatchInit")) == NULL) 133 137 symbol = NSLookupSymbolInModule(module, "__Z11SCPatchInitP13SCPatchParams"); … … 141 145 else 142 146 { 147 NSLinkEditErrors errors; 148 int errorNumber; 149 const char *fileName, *errorString; 150 NSLinkEditError(&errors, &errorNumber, &fileName, &errorString); 151 // XXX need to pass back to caller 152 SCPLLog("NSLinkModule: NSLinkEditError %d (%d) loading %s (%s)", errors, errorNumber, fileName, errorString); 143 153 err = err_couldnt_load_injection_bundle; 144 154 }
Note:
See TracChangeset
for help on using the changeset viewer.