25
25
@interface SSYPathWatch : NSObject {
26
26
NSString * m_path ;
27
27
id m_userInfo ;
28
- NSInteger m_fileDescriptor ;
28
+ uint32_t m_fileDescriptor ;
29
29
NSThread * m_notifyThread ;
30
30
}
31
31
32
32
@property (retain ) NSString * path ;
33
33
@property (retain ) id userInfo ;
34
- @property (assign ) NSInteger fileDescriptor ;
34
+ @property (assign ) uint32_t fileDescriptor ;
35
35
@property (assign ) NSThread * notifyThread ;
36
36
37
37
@end
@@ -120,7 +120,7 @@ camping on kevent(), outside of these two blocks of code, but,
120
120
oh, well if you don't try to write perfect code, you'll have
121
121
lots of bugs. */
122
122
123
- NSInteger fileDescriptor ;
123
+ int fileDescriptor ;
124
124
@synchronized (self) {
125
125
NSAutoreleasePool * pool1 = [[NSAutoreleasePool alloc ] init ] ;
126
126
@@ -210,7 +210,7 @@ -(id)init {
210
210
[self setIsWatching: YES ] ;
211
211
[self setPathWatches: [NSMutableSet set ]] ;
212
212
213
- NSInteger kqueueFileDescriptor = kqueue () ;
213
+ uint32_t kqueueFileDescriptor = kqueue () ;
214
214
if (kqueueFileDescriptor == -1 ) {
215
215
NSLog (@" Internal Error 153-9092. Failed creating kqueue" ) ;
216
216
// See http://lists.apple.com/archives/Objc-language/2008/Sep/msg00133.html ...
@@ -335,7 +335,7 @@ - (oneway void)release {
335
335
// Close any file descriptors which might still be open
336
336
for (SSYPathWatch* pathWatch in [self pathWatches ]) {
337
337
// Unregister kqueue of the target pathWatch
338
- NSInteger fileDescriptor = [pathWatch fileDescriptor ] ;
338
+ uint32_t fileDescriptor = [pathWatch fileDescriptor ] ;
339
339
NSInteger result = close (fileDescriptor) ;
340
340
if (result != 0 ) {
341
341
}
@@ -352,7 +352,7 @@ - (oneway void)release {
352
352
}
353
353
#endif
354
354
355
- NSInteger kqfd = [self kqueueFileDescriptor ] ;
355
+ uint32_t kqfd = [self kqueueFileDescriptor ] ;
356
356
357
357
// The following causes the watcher thread to exit in Mac OS 10.6,
358
358
// but not in Mac OS 10.5.
@@ -384,7 +384,7 @@ - (BOOL)addPath:(NSString*)path
384
384
BOOL ok = YES ;
385
385
386
386
// Get file descriptor for given path
387
- NSInteger fileDescriptor = open ([path UTF8String ], O_RDONLY) ;
387
+ uint32_t fileDescriptor = open ([path UTF8String ], O_RDONLY) ;
388
388
if (fileDescriptor == -1 ) {
389
389
if (error_p) {
390
390
NSDictionary * userInfo = [NSDictionary dictionaryWithObjectsAndKeys:
0 commit comments