@@ -110,7 +110,7 @@ - (NSArray *)nodesUnderPath:(NSString *)path
110110 NSUInteger i = [indexes firstIndex ];
111111 for (; NSNotFound != i; i = [indexes indexGreaterThanIndex: i]) {
112112 @autoreleasepool { // REQUIRED otherwise the heap blows up (try it on a 50000 entry zip file)
113- NSString *const entryPath = [_archive nameOfEntry: i];
113+ NSString *const entryPath = [_archive nameOfEntry: ( int ) i];
114114 if (!entryPath)
115115 continue ;
116116
@@ -182,7 +182,7 @@ - (NSArray *)nodesUnderPath:(NSString *)path
182182 #endif
183183
184184 BOOL const isEntrylessFolder = !PGEqualObjects (subpath, entryPath);
185- BOOL const isFile = !isEntrylessFolder && ![_archive entryIsDirectory: i];
185+ BOOL const isFile = !isEntrylessFolder && ![_archive entryIsDirectory: ( int ) i];
186186// NSLog(@"%@\tsubpath '%@', isEntrylessFolder %u, isFile %u", StringAtDepth(depth),
187187// [subpath substringFromIndex:194], isEntrylessFolder, isFile);
188188
@@ -191,7 +191,7 @@ - (NSArray *)nodesUnderPath:(NSString *)path
191191 [identifier setNaturalDisplayName: [subpath lastPathComponent ]];
192192 PGNode *const node = [[[PGNode alloc ] initWithParent: parent identifier: identifier] autorelease ];
193193 if (isFile)
194- [node setDataProvider: [[[PGArchiveDataProvider alloc ] initWithArchive: _archive entry: i] autorelease ]];
194+ [node setDataProvider: [[[PGArchiveDataProvider alloc ] initWithArchive: _archive entry: ( int ) i] autorelease ]];
195195 else {
196196 [node setDataProvider: [[[PGFolderDataProvider alloc ] init ] autorelease ]];
197197 if (isEntrylessFolder) {
@@ -505,10 +505,10 @@ - (NSString *)PG_commonRootPath
505505 NSInteger i;
506506 NSString *root = nil ;
507507 for (i = 0 ; i < [self numberOfEntries ]; i++) {
508- NSString *entryName = [self nameOfEntry: i];
508+ NSString *entryName = [self nameOfEntry: ( int ) i];
509509 if (PG_entryIsInvisibleForName (entryName))// if([self PG_entryIsInvisibleForName:entryName])
510510 continue ;
511- if (![self entryIsDirectory: i]) entryName = [entryName stringByDeletingLastPathComponent ];
511+ if (![self entryIsDirectory: ( int ) i]) entryName = [entryName stringByDeletingLastPathComponent ];
512512 else if ([entryName hasSuffix: @" /" ]) entryName = [entryName substringToIndex: [entryName length ] - 1 ];
513513 if (!root) root = entryName;
514514 else while (!PGEqualObjects (root, entryName)) {
@@ -520,7 +520,7 @@ - (NSString *)PG_commonRootPath
520520}
521521- (OSType)PG_OSTypeForEntry : (int )entry
522522{
523- return [self entryIsDirectory: entry] ? ' fold' : [[[self attributesOfEntry: entry] objectForKey: NSFileHFSTypeCode ] unsignedLongValue ];
523+ return [self entryIsDirectory: entry] ? ' fold' : [[[self attributesOfEntry: entry] objectForKey: NSFileHFSTypeCode ] unsignedIntValue ];
524524}
525525
526526@end
0 commit comments