diff --git a/ChangeLog b/ChangeLog index 479ff9b..75b315d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,7 @@ * EOAccess/EOModel.m: Appplied David Ayers patch for programmatic model manipulation. Fixed typo. Use NSFileManager rather than mkdir(). Tidied some use of autorelease for memory efficiency etc. + * EOControl/EOGenericRecord.m: update to use GSFindInstanceVariable() 2002-11-26 Manuel Guesdon diff --git a/EOAccess/EOModel.m b/EOAccess/EOModel.m index b1a3af2..21b69b7 100644 --- a/EOAccess/EOModel.m +++ b/EOAccess/EOModel.m @@ -313,8 +313,11 @@ NSString *EOEntityLoadedNotification = @"EOEntityLoadedNotification"; NSAssert(name,@"No entityt name"); entity = [_entitiesByName objectForKey: name]; - entity = [self _verifyBuiltEntityObject: entity - named: name]; + if (entiry != nil) + { + entity = [self _verifyBuiltEntityObject: entity + named: name]; + } return entity; } @@ -1036,8 +1039,8 @@ NSString *EOEntityLoadedNotification = @"EOEntityLoadedNotification"; //OK [self loadAllModelObjects]; [self willChange]; - ASSIGN(_path,path); - [self setName: [[path lastPathComponents] stringByDeletingPathExtension]]; + ASSIGN(_path, path); + [self setName: [[path lastPathComponent] stringByDeletingPathExtension]]; } - (EOEntity*) _entityForClass: (Class)aClass diff --git a/EOControl/EOGenericRecord.m b/EOControl/EOGenericRecord.m index a1e8afc..f9bd495 100644 --- a/EOControl/EOGenericRecord.m +++ b/EOControl/EOGenericRecord.m @@ -181,8 +181,8 @@ static const char _c_id[2] = { _C_ID, NULL }; //used to allow derived object implementation - (BOOL)_infoForInstanceVariableNamed: (NSString*)name retType: (const char**)type - retSize: (unsigned*)size - retOffset: (unsigned*)offset + retSize: (unsigned int*)size + retOffset: (int*)offset { BOOL ok; @@ -192,7 +192,7 @@ static const char _c_id[2] = { _C_ID, NULL }; retSize:size retOffset:offset]; */ - ok = GSInstanceVariableInfo(self, name, type, size, offset); + ok = GSFindInstanceVariable(self, [name cString], type, size, offset); EOFLOGObjectLevelArgs(@"EOGenericRecordKVC", @"Super InstanceVar named %@:%s",