Revision: 4134
          http://skim-app.svn.sourceforge.net/skim-app/?rev=4134&view=rev
Author:   hofman
Date:     2008-07-05 06:41:09 -0700 (Sat, 05 Jul 2008)

Log Message:
-----------
We shouldn't ignore fragments when removing all EAs.

Modified Paths:
--------------
    trunk/SkimNotes/SKNExtendedAttributeManager.m

Modified: trunk/SkimNotes/SKNExtendedAttributeManager.m
===================================================================
--- trunk/SkimNotes/SKNExtendedAttributeManager.m       2008-07-05 13:33:08 UTC 
(rev 4133)
+++ trunk/SkimNotes/SKNExtendedAttributeManager.m       2008-07-05 13:41:09 UTC 
(rev 4134)
@@ -111,7 +111,7 @@
     [super dealloc];
 }
 
-- (NSArray *)extendedAttributeNamesAtPath:(NSString *)path 
traverseLink:(BOOL)follow error:(NSError **)error;
+- (NSArray *)extendedAttributeNamesAtPath:(NSString *)path 
traverseLink:(BOOL)follow includeFragments:(BOOL)fragments error:(NSError 
**)error;
 {
     const char *fsPath = [path fileSystemRepresentation];
     
@@ -155,7 +155,7 @@
         if(namebuf[idx] == '\0'){
             attribute = [[NSString alloc] initWithBytes:&namebuf[start] 
length:(idx - start) encoding:NSUTF8StringEncoding];
             // ignore fragments
-            if(attribute && (namePrefix == nil || [attribute 
hasPrefix:namePrefix] == NO)) [attrs addObject:attribute];
+            if(attribute && (fragments || namePrefix == nil || [attribute 
hasPrefix:namePrefix] == NO)) [attrs addObject:attribute];
             [attribute release];
             attribute = nil;
             start = idx + 1;
@@ -166,6 +166,11 @@
     return attrs;
 }
 
+- (NSArray *)extendedAttributeNamesAtPath:(NSString *)path 
traverseLink:(BOOL)follow error:(NSError **)error;
+{
+    return [self extendedAttributeNamesAtPath:path traverseLink:follow 
includeFragments:NO error:error];
+}
+
 - (NSDictionary *)allExtendedAttributesAtPath:(NSString *)path 
traverseLink:(BOOL)follow error:(NSError **)error;
 {
     NSError *anError = nil;
@@ -448,7 +453,7 @@
 
 - (BOOL)removeAllExtendedAttributesAtPath:(NSString *)path 
traverseLink:(BOOL)follow error:(NSError **)error;
 {
-    NSArray *allAttributes = [self extendedAttributeNamesAtPath:path 
traverseLink:follow error:error];
+    NSArray *allAttributes = [self extendedAttributeNamesAtPath:path 
traverseLink:follow includeFragments:YES error:error];
     if  (nil == allAttributes)
         return NO;
     


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to