diff -Nru ftp.app-0.5/AppController.h ftp.app-0.6/AppController.h --- ftp.app-0.5/AppController.h 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/AppController.h 2017-01-19 09:34:42.000000000 +0000 @@ -2,7 +2,7 @@ Project: FTP - Copyright (C) 2005-2013 Riccardo Mottola + Copyright (C) 2005-2016 Riccardo Mottola Author: Riccardo Mottola @@ -36,44 +36,53 @@ @interface AppController : NSObject { - IBOutlet NSWindow *mainWin; - IBOutlet NSTableView *localView; - IBOutlet NSTableView *remoteView; - IBOutlet NSPopUpButton *localPath; - IBOutlet NSPopUpButton *remotePath; - IBOutlet NSButton *buttDownload; - IBOutlet NSButton *buttUpload; - IBOutlet NSTextField *infoMessage; - IBOutlet NSTextField *infoSpeed; - IBOutlet NSTextField *infoSize; - IBOutlet NSProgressIndicator *progBar; + IBOutlet NSMenu *mainMenu; + + IBOutlet NSWindow *mainWin; + IBOutlet NSTableView *localView; + IBOutlet NSTableView *remoteView; + IBOutlet NSPopUpButton *localPath; + IBOutlet NSPopUpButton *remotePath; + IBOutlet NSButton *buttDownload; + IBOutlet NSButton *buttUpload; + IBOutlet NSTextField *infoMessage; + IBOutlet NSTextField *infoSpeed; + IBOutlet NSTextField *infoSize; + IBOutlet NSProgressIndicator *progBar; - IBOutlet NSWindow *logWin; - IBOutlet NSTextView *logTextField; + IBOutlet NSWindow *logWin; + IBOutlet NSTextView *logTextField; - IBOutlet NSPanel *connectPanel; - IBOutlet NSTextField *connAddress; - IBOutlet NSTextField *connPort; - IBOutlet NSTextField *connUser; - IBOutlet NSTextField *connPass; - IBOutlet NSButton *connAnon; - - IBOutlet NSPanel *prefPanel; - IBOutlet NSMatrix *portType; + IBOutlet NSPanel *connectPanel; + IBOutlet NSBox *connServerBox; + IBOutlet NSBox *connAccountBox; + IBOutlet NSTextField *connAddress; + IBOutlet NSTextField *connPort; + IBOutlet NSTextField *connUser; + IBOutlet NSTextField *connPass; + IBOutlet NSButton *connAnon; + IBOutlet NSButton *connCancelButt; + IBOutlet NSButton *connConnectButt; + + IBOutlet NSPanel *prefPanel; + IBOutlet NSMatrix *portType; + IBOutlet NSButton *prefCancelButt; + IBOutlet NSButton *prefSaveButt; - NSMutableDictionary *textAttributes; + NSMutableDictionary *textAttributes; - FileTable *localTableData; - FileTable *remoteTableData; - FtpClient *ftp; - LocalClient *local; - - @private connectionModes connMode; - @private struct timeval beginTimeVal; - @private unsigned long long transferSize; - @private BOOL threadRunning; + FileTable *localTableData; + FileTable *remoteTableData; + FtpClient *ftp; + LocalClient *local; + + NSMutableArray *filesInProcess; + @private connectionModes connMode; + @private NSTimeInterval beginTimeVal; + @private unsigned long long transferSize; + @private BOOL threadRunning; - @private NSConnection *doConnection; + @private NSConnection *doConnection; } - (void)applicationDidFinishLaunching:(NSNotification *)aNotif; @@ -101,9 +110,9 @@ - (void)setThreadRunningState:(BOOL)flag; -- (void)setTransferBegin:(NSString *)name :(unsigned long long)size; -- (void)setTransferProgress:(NSNumber *)bytesTransferred; -- (void)setTransferEnd:(NSNumber *)bytesTransferred; +- (oneway void)setTransferBegin:(in bycopy NSString *)name :(unsigned long long)size; +- (oneway void)setTransferProgress:(in bycopy NSNumber *)bytesTransferred; +- (oneway void)setTransferEnd:(in bycopy NSNumber *)bytesTransferred; /** closes the open connections and quits the session with the remote server */ - (IBAction)disconnect:(id)sender; @@ -116,7 +125,7 @@ /** Called by the server object to register itself */ - (void)setServer:(id)anObject; -- (void)appendTextToLog:(NSString *)textChunk; +- (oneway void)appendTextToLog:(NSString *)textChunk; - (IBAction)showConnPanel:(id)sender; - (IBAction)connectConn:(id)sender; @@ -132,8 +141,10 @@ - (void)performRetrieveFile; - (void)performStoreFile; -- (void)retrieveFiles:(NSArray *)files; -- (void)storeFiles:(NSArray *)files; +- (void)retrieveFiles; +- (oneway void)fileRetrieved:(BOOL)success; +- (void)storeFiles; +- (oneway void)fileStored:(BOOL)success; @end diff -Nru ftp.app-0.5/AppController.m ftp.app-0.6/AppController.m --- ftp.app-0.5/AppController.m 2015-02-16 23:51:37.000000000 +0000 +++ ftp.app-0.6/AppController.m 2017-03-15 16:50:09.000000000 +0000 @@ -1,7 +1,7 @@ /* Project: FTP - Copyright (C) 2005-2015 Riccardo Mottola + Copyright (C) 2005-2016 Riccardo Mottola Author: Riccardo Mottola @@ -63,6 +63,53 @@ - (void)awakeFromNib { + NSMenu *menu; + NSMenuItem *mi; + + /* connection panel */ + [connServerBox setTitle:NSLocalizedString(@"Server Address and Port", @"Server Address and Port")]; + [connAccountBox setTitle:NSLocalizedString(@"Account", @"Account")]; + [connectPanel setTitle:NSLocalizedString(@"Connect", @"Connect")]; + [connAnon setTitle:NSLocalizedString(@"Anonymous", @"Anonymous connection")]; + [connCancelButt setTitle:NSLocalizedString(@"Cancel", @"Cancel")]; + [connConnectButt setTitle:NSLocalizedString(@"Connect (action)", @"Connect (action)")]; + + /* main window */ + [[localPath itemAtIndex:0] setTitle:NSLocalizedString(@"local view", @"local view")]; + [[remotePath itemAtIndex:0] setTitle:NSLocalizedString(@"remote view", @"remote view")]; + [[[localView tableColumnWithIdentifier:@"filename"] headerCell] setStringValue:NSLocalizedString(@"Name", @"filename table")]; + [[[remoteView tableColumnWithIdentifier:@"filename"] headerCell] setStringValue:NSLocalizedString(@"Name", @"filename table")]; + + /* menus */ + mi = [mainMenu itemWithTitle:@"Local"]; + menu = [mi submenu]; + [menu setTitle:NSLocalizedString(@"Local", @"Local")]; + mi = [menu itemWithTag:1]; + [mi setTitle:NSLocalizedString(@"Rename...", @"Rename...")]; + mi = [menu itemWithTag:2]; + [mi setTitle:NSLocalizedString(@"New Folder...", @"New Folder....")]; + mi = [menu itemWithTag:3]; + [mi setTitle:NSLocalizedString(@"Delete", @"Delete")]; + mi = [menu itemWithTag:4]; + [mi setTitle:NSLocalizedString(@"Refresh", @"Refresh")]; + + mi = [mainMenu itemWithTitle:@"Remote"]; + menu = [mi submenu]; + [menu setTitle:NSLocalizedString(@"Remote", @"Remote")]; + mi = [menu itemWithTag:1]; + [mi setTitle:NSLocalizedString(@"Rename...", @"Rename...")]; + mi = [menu itemWithTag:2]; + [mi setTitle:NSLocalizedString(@"New Folder...", @"New Folder....")]; + mi = [menu itemWithTag:3]; + [mi setTitle:NSLocalizedString(@"Delete", @"Delete")]; + mi = [menu itemWithTag:4]; + [mi setTitle:NSLocalizedString(@"Refresh", @"Refresh")]; + + /* log */ + [logWin setTitle:NSLocalizedString(@"Connection Log", @"Connection Log")]; + + [logTextField setSelectable:YES]; + [logTextField setEditable:NO]; } - (void)applicationDidFinishLaunching:(NSNotification *)aNotif @@ -78,12 +125,12 @@ defaults = [NSUserDefaults standardUserDefaults]; readValue = [defaults stringForKey:connectionModeKey]; - /* if no value was set for the key we set port as mode */ + /* if no value was set for the key we set passive as mode */ if ([readValue isEqualToString:@"default"]) connMode = defaultMode; - else if ([readValue isEqualToString:@"port"] || readValue == nil) + else if ([readValue isEqualToString:@"port"] ) connMode = portMode; - else if ([readValue isEqualToString:@"passive"]) + else if ([readValue isEqualToString:@"passive"] || readValue == nil) connMode = passiveMode; else NSLog(@"Unrecognized value in user preferences for %@: %@", connectionModeKey, readValue); @@ -335,7 +382,7 @@ else if (sender == remoteTableData) { NSLog(@"will upload: %@", arr); - [self storeFiles:arr]; + [self storeFiles]; } [arr release]; } @@ -373,92 +420,137 @@ /** retrieves using selection, by constructing an array and calling retrieveFiles */ - (void)performRetrieveFile { - NSMutableArray *selArray; NSEnumerator *elemEnum; FileElement *fileEl; id currEl; /* make a copy of the selection */ - selArray = [[NSMutableArray alloc] init]; + [filesInProcess release]; + filesInProcess = [[NSMutableArray alloc] init]; elemEnum = [remoteView selectedRowEnumerator]; while ((currEl = [elemEnum nextObject]) != nil) { fileEl = [remoteTableData elementAtIndex:[currEl intValue]]; - [selArray addObject:fileEl]; + [filesInProcess addObject:fileEl]; } - [self retrieveFiles:selArray]; - [selArray release]; + [self retrieveFiles]; } /** stores using selection, by constructing an array and calling storeFiles */ - (void)performStoreFile { - NSMutableArray *selArray; NSEnumerator *elemEnum; FileElement *fileEl; id currEl; /* make a copy of the selection */ - selArray = [[NSMutableArray alloc] init]; + [filesInProcess release]; + filesInProcess = [[NSMutableArray alloc] init]; elemEnum = [localView selectedRowEnumerator]; while ((currEl = [elemEnum nextObject]) != nil) { fileEl = [localTableData elementAtIndex:[currEl intValue]]; - [selArray addObject:fileEl]; + [filesInProcess addObject:fileEl]; } - [self storeFiles:selArray]; - [selArray release]; + [self storeFiles]; } /** Retrieves Array of FileElements */ -- (void)retrieveFiles:(NSArray *)files +- (void)retrieveFiles { - NSUInteger i; - - [self setThreadRunningState:YES]; - for (i = 0; i < [files count]; i++) + if([filesInProcess count] > 0) { FileElement *fEl; - fEl = [files objectAtIndex:i]; - NSLog(@"should download (performStore): %@", [fEl name]); - if ([ftp retrieveFile:fEl to:local beingAt:0]) + [self setThreadRunningState:YES]; + fEl = [filesInProcess objectAtIndex:0]; + NSLog(@"should download (performRETRIEVE): %@", [fEl name]); + [ftp retrieveFile:fEl to:local]; + } +} + +/* called by the worker thread when the element got processed */ +- (oneway void)fileRetrieved:(BOOL)success +{ + FileElement *fEl; + + fEl = [filesInProcess objectAtIndex:0]; + if (success) + { + if (![localTableData containsFileName:[fEl name]]) { - if (![localTableData containsFileName:[fEl name]]) - [localTableData addObject:fEl]; + FileElement *fEl2; + + fEl2 = [[FileElement alloc] initWithPath:[[local workingDir] stringByAppendingPathComponent:[fEl name]] andAttributes:[fEl attributes]]; + [localTableData addObject:fEl2]; + [fEl2 release]; } } - [localView deselectAll:self]; - [localView reloadData]; - [self setThreadRunningState:NO]; + [filesInProcess removeObjectAtIndex:0]; + if ([filesInProcess count] > 0) + { + [self retrieveFiles]; + } + else + { + [localView deselectAll:self]; + [localView reloadData]; + [self setThreadRunningState:NO]; + [filesInProcess release]; + filesInProcess = nil; + } } /** Stores Array of FileElements */ -- (void)storeFiles:(NSArray *)files +- (void)storeFiles { - NSUInteger i; - - [self setThreadRunningState:YES]; - for (i = 0; i < [files count]; i++) + if([filesInProcess count] > 0) { FileElement *fEl; - fEl = [files objectAtIndex:i]; - NSLog(@"should upload (performStore): %@", [fEl name]); - if ([ftp storeFile:fEl from:local beingAt:0]) + [self setThreadRunningState:YES]; + fEl = [filesInProcess objectAtIndex:0]; + NSLog(@"should download (performStore): %@", [fEl name]); + [ftp storeFile:fEl from:local]; + } +} + +/* called by the worker thread when the element got processed */ +- (oneway void)fileStored:(BOOL)success +{ + FileElement *fEl; + + fEl = [filesInProcess objectAtIndex:0]; + if (success) + { + if (![remoteTableData containsFileName:[fEl name]]) { - if (![remoteTableData containsFileName:[fEl name]]) - [remoteTableData addObject:fEl]; + FileElement *fEl2; + + fEl2 = [[FileElement alloc] initWithPath:[[ftp workingDir] stringByAppendingPathComponent:[fEl name]] andAttributes:[fEl attributes]]; + [remoteTableData addObject:fEl2]; + [fEl2 release]; } } - [remoteView deselectAll:self]; - [remoteView reloadData]; - [self setThreadRunningState:NO]; + [filesInProcess removeObjectAtIndex:0]; + if ([filesInProcess count] > 0) + { + [self storeFiles]; + } + else + { + [remoteView deselectAll:self]; + [remoteView reloadData]; + [self setThreadRunningState:NO]; + [filesInProcess release]; + filesInProcess = nil; + } } + - (IBAction)downloadButton:(id)sender { if (threadRunning) @@ -502,8 +594,8 @@ for (i = 0; i < [selArray count]; i++) { fileEl = [selArray objectAtIndex:i]; - [local deleteFile:fileEl beingAt:0]; - [localTableData removeObject:fileEl]; + if([local deleteFile:fileEl beingAt:0]) + [localTableData removeObject:fileEl]; } [localView deselectAll:self]; [localView reloadData]; @@ -531,8 +623,8 @@ for (i = 0; i < [selArray count]; i++) { fileEl = [selArray objectAtIndex:i]; - [ftp deleteFile:fileEl beingAt:0]; - [remoteTableData removeObject:fileEl]; + if ([ftp deleteFile:fileEl beingAt:0]) + [remoteTableData removeObject:fileEl]; } [remoteView deselectAll:self]; [remoteView reloadData]; @@ -685,17 +777,11 @@ [self readDirWith:ftp toTable:remoteTableData andView:remoteView]; } -- (void)setTransferBegin:(NSString *)name :(unsigned long long)size +- (oneway void)setTransferBegin:(in bycopy NSString *)name :(unsigned long long)size { [infoMessage setStringValue:name]; [progBar setDoubleValue:0]; -#ifdef WIN32 - DWORD msecs = timeGetTime(); - beginTimeVal.tv_sec=msecs/1000; - beginTimeVal.tv_usec=(msecs - beginTimeVal.tv_sec*1000) * 1000; -#else - gettimeofday(&beginTimeVal, NULL); -#endif + beginTimeVal = [NSDate timeIntervalSinceReferenceDate]; transferSize = size; NSLog(@"begin transfer size: %llu", transferSize); if (transferSize == 0) @@ -706,9 +792,9 @@ [mainWin displayIfNeeded]; } -- (void)setTransferProgress:(NSNumber *)bytesTransferred +- (oneway void)setTransferProgress:(in bycopy NSNumber *)bytesTransferred { - struct timeval currTimeVal; + NSTimeInterval currTimeVal; float speed; NSString *speedStr; NSString *sizeStr; @@ -716,14 +802,8 @@ unsigned long long bytes; bytes = [bytesTransferred unsignedLongLongValue]; -#ifdef WIN32 - DWORD msecs = timeGetTime(); - currTimeVal.tv_sec=msecs/1000; - currTimeVal.tv_usec=(msecs - currTimeVal.tv_sec*1000) * 1000; -#else - gettimeofday(&currTimeVal, NULL); -#endif - speed = (float)((double)bytes / (double)(currTimeVal.tv_sec - beginTimeVal.tv_sec)); + currTimeVal = [NSDate timeIntervalSinceReferenceDate]; + speed = (float)((double)bytes / (double)(currTimeVal - beginTimeVal)); if (transferSize > 0) { @@ -751,14 +831,12 @@ sizeStr = [sizeStr initWithFormat:@"%3.2f : %3.2f MB", (double)bytes/(1024*1024), (double)transferSize/(1024*1024)]; [infoSize setStringValue:sizeStr]; [sizeStr release]; - - [[NSRunLoop currentRunLoop] runUntilDate:[NSDate distantPast]]; } -- (void)setTransferEnd:(NSNumber *)bytesTransferred +- (oneway void)setTransferEnd:(in bycopy NSNumber *)bytesTransferred { - struct timeval currTimeVal; - double deltaT; + NSTimeInterval currTimeVal; + NSTimeInterval deltaT; float speed; NSString *speedStr; NSString *sizeStr; @@ -766,15 +844,8 @@ unsigned long long bytes; bytes = [bytesTransferred unsignedLongLongValue]; - -#ifdef WIN32 - DWORD msecs = timeGetTime(); - currTimeVal.tv_sec=msecs/1000; - currTimeVal.tv_usec=(msecs - currTimeVal.tv_sec*1000) * 1000; -#else - gettimeofday(&currTimeVal, NULL); -#endif - deltaT = (currTimeVal.tv_sec - beginTimeVal.tv_sec)+((double)(currTimeVal.tv_usec - beginTimeVal.tv_usec)/1000000); + currTimeVal = [NSDate timeIntervalSinceReferenceDate]; + deltaT = (currTimeVal - beginTimeVal); speed = (float)((double)bytes / deltaT); NSLog(@"Elapsed time: %f", (float)deltaT); percent = ((double)bytes / (double)transferSize) * 100; @@ -891,7 +962,7 @@ ftp = (FtpClient*)[anObject retain]; } -- (void)appendTextToLog:(NSString *)textChunk +- (oneway void)appendTextToLog:(NSString *)textChunk { NSAttributedString *attrStr; diff -Nru ftp.app-0.5/ChangeLog ftp.app-0.6/ChangeLog --- ftp.app-0.5/ChangeLog 2015-02-16 23:51:38.000000000 +0000 +++ ftp.app-0.6/ChangeLog 2017-07-28 10:44:57.000000000 +0000 @@ -1,3 +1,135 @@ +2017-27-28 Riccardo Mottola + + * ftpclient.m + Track and NSLog() non-200 port response. + +2017-03-02 Riccardo Mottola + + * fileTable.m + Further razionalize parsing of lines without user or link info. Use suffix for dir/file heuristics on links. + +2017-03-02 Riccardo Mottola + + * fileTable.m + Razionalize parsing with 8 or 9 elements, improve link handling by extracting link information from the dir block. + +2016-11-24 Riccardo Mottola + + * AppController.m + More localize Local and Remote menus. + +2016-11-18 Riccardo Mottola + + * AppController.m + More localization work. + +2016-09-27 Riccardo Mottola + + * AppController.m + * Resources/GetName.nib + * Resources/MainMenu.nib + Localization work: make nib generic + +2016-09-16 Riccardo Mottola + + * localclient.m + use isAbsolutePath! + +2016-08-23 Riccardo Mottola + + * fileTable.m + cleanup and simplify housekeeping of the sorted array. + +2016-08-23 Riccardo Mottola + + * fileTable.m + Do not keep in the sortedArray just name and index, but really just the sorted object pointers. + +2016-08-08 Riccardo Mottola + + * AppController.m + Do not run runloop, no longer needed. + +2016-08-06 Riccardo Mottola + + * AppController.h + * AppController.m + * ftpclient.h + * ftpclient.m + make store/retrieve client methods return immediately oneway void and then + use call-back method fileStored/fileRetrieved to complete action + +2016-08-02 Riccardo Mottola + + * client.h + * client.m + make also workDirSplit return result bycopy + +2016-08-02 Riccardo Mottola + + * fileElement.m + Implement coder methods for bycopy. + +2016-08-02 Riccardo Mottola + + * AppController.m + When Retrieving, set file-element path since it can be different than source. + +2016-08-02 Riccardo Mottola + + * client.h + * client.m + * ftpclient.m + * localclient.m + Pass directory elements array by copy + +2016-08-01 Riccardo Mottola + + * AppController.h + * AppController.m + Pass progress parameters by copy + +2016-08-01 Riccardo Mottola + + * AppController.h + * AppController.m + Use NSTimeInterval for speed calculations. + +2016-07-08 Riccardo Mottola + + * client.h + * client.m + * ftpclient.m + * localclient.m + * AppController.m + Delete files may fail, handle result. + +2016-07-07 Riccardo Mottola + + * AppController.m + Use passive as default. + +2016-07-03 Riccardo Mottola + + * AppController.h + * AppController.m + Mark progress methods as oneway. + +2016-07-03 Riccardo Mottola + + * ftpclient.m + Open local file in binary mode (needed on Windows) + +2016-05-16 Riccardo Mottola + + * ftpclient.m + Open files in binary mode (fixes on Windows), check more carefully for sent bytes. + +2015-09-04 Riccardo Mottola + + * ftpclient.m + Fix socktype for NetBSD. + 2015-02-11 Riccardo Mottola * AppController.m diff -Nru ftp.app-0.5/client.h ftp.app-0.6/client.h --- ftp.app-0.5/client.h 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/client.h 2016-08-08 21:32:39.000000000 +0000 @@ -2,7 +2,7 @@ Project: FTP - Copyright (C) 2005-2013 Free Software Foundation + Copyright (C) 2005-2016 Free Software Foundation Author: Riccardo Mottola @@ -47,22 +47,22 @@ - (id)initWithController:(id)cont; /** returns the current working directory */ -- (NSString *)workingDir; +- (bycopy NSString *)workingDir; - (void)setWorkingDirWithCString:(char *)dir; - (void)setWorkingDir:(NSString *)dir; - (void)changeWorkingDir:(NSString *)dir; - (BOOL)createNewDir:(NSString *)dir; -- (void)deleteFile:(FileElement *)file beingAt:(int)depth; +- (BOOL)deleteFile:(FileElement *)file beingAt:(int)depth; - (BOOL)renameFile:(FileElement *)file to:(NSString *)name; -- (NSArray *)workDirSplit; +- (bycopy NSArray *)workDirSplit; /** returns an array with the directory listing */ -- (NSArray *)dirContents; +- (bycopy NSArray *)dirContents; /** returns the current home directory */ -- (NSString *)homeDir; +- (bycopy NSString *)homeDir; @end diff -Nru ftp.app-0.5/client.m ftp.app-0.6/client.m --- ftp.app-0.5/client.m 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/client.m 2017-01-19 09:34:42.000000000 +0000 @@ -1,7 +1,7 @@ /* Project: FTP - Copyright (C) 2005-2013 Free Software Foundation + Copyright (C) 2005-2016 Free Software Foundation Author: Riccardo Mottola @@ -59,12 +59,12 @@ [super dealloc]; } -- (NSString *)workingDir +- (bycopy NSString *)workingDir { return workingDir; } -- (NSString *)homeDir +- (bycopy NSString *)homeDir { return homeDir; } @@ -86,7 +86,7 @@ [self setWorkingDir:dir]; } -- (NSArray *)workDirSplit +- (bycopy NSArray *)workDirSplit { NSMutableArray *reversedList; NSArray *list; @@ -100,10 +100,10 @@ en = [list reverseObjectEnumerator]; while ((currElement = [en nextObject])) [reversedList addObject:currElement]; - return [reversedList retain]; + return reversedList; } -- (NSArray *)dirContents +- (bycopy NSArray *)dirContents { NSLog(@"override me! dirContents superclass method"); return nil; @@ -115,9 +115,10 @@ return NO; } -- (void)deleteFile:(FileElement *)file beingAt:(int)depth +- (BOOL)deleteFile:(FileElement *)file beingAt:(int)depth { NSLog(@"override me! deleteFile superclass method"); + return NO; } - (BOOL)renameFile:(FileElement *)file to:(NSString *)name diff -Nru ftp.app-0.5/debian/changelog ftp.app-0.6/debian/changelog --- ftp.app-0.5/debian/changelog 2017-01-08 05:01:23.000000000 +0000 +++ ftp.app-0.6/debian/changelog 2017-09-11 11:08:31.000000000 +0000 @@ -1,3 +1,14 @@ +ftp.app (0.6-1) unstable; urgency=medium + + * Team upload. + + [ Gürkan Myczko ] + * New upstream version. + * Bump standards version to 4.0.0. + * Bump debhelper version to 10. + + -- Gürkan Myczko Mon, 11 Sep 2017 13:08:31 +0200 + ftp.app (0.5-1) unstable; urgency=medium * Team upload. diff -Nru ftp.app-0.5/debian/compat ftp.app-0.6/debian/compat --- ftp.app-0.5/debian/compat 2017-01-08 04:38:41.000000000 +0000 +++ ftp.app-0.6/debian/compat 2017-09-11 11:08:31.000000000 +0000 @@ -1 +1 @@ -9 +10 diff -Nru ftp.app-0.5/debian/control ftp.app-0.6/debian/control --- ftp.app-0.5/debian/control 2017-01-08 04:42:07.000000000 +0000 +++ ftp.app-0.6/debian/control 2017-09-11 11:08:31.000000000 +0000 @@ -3,8 +3,8 @@ Priority: optional Maintainer: Federico Gimenez Nieto Uploaders: Debian GNUstep maintainers -Build-Depends: debhelper (>= 9), libgnustep-gui-dev, gnustep-make, imagemagick -Standards-Version: 3.9.8 +Build-Depends: debhelper (>= 10), libgnustep-gui-dev, gnustep-make, imagemagick +Standards-Version: 4.0.0 Vcs-Git: https://anonscm.debian.org/git/pkg-gnustep/ftp.app.git Vcs-Browser: https://anonscm.debian.org/git/pkg-gnustep/ftp.app.git Homepage: http://www.nongnu.org/gap/ftp/ diff -Nru ftp.app-0.5/debian/copyright ftp.app-0.6/debian/copyright --- ftp.app-0.5/debian/copyright 2017-01-08 04:38:41.000000000 +0000 +++ ftp.app-0.6/debian/copyright 2017-09-11 11:08:31.000000000 +0000 @@ -9,8 +9,8 @@ License: - Copyright (C) 2005-2008 Riccardo Mottola (multix) - Copyright (C) 2005-2008 Free Software Foundation + Copyright (C) 2005-2017 Riccardo Mottola (multix) + Copyright (C) 2005-2017 Free Software Foundation This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -47,6 +47,6 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA The Debian packaging is -Copyright (c) 2006-2008 Gürkan Sengün a +Copyright (c) 2006-2017 Gürkan Myczko Copyright (c) 2010-2012 Federico Gimenez Nieto and is licensed under the GPL-2, see `/usr/share/common-licenses/GPL-2'. diff -Nru ftp.app-0.5/debian/FTP.1 ftp.app-0.6/debian/FTP.1 --- ftp.app-0.5/debian/FTP.1 2017-01-08 04:38:41.000000000 +0000 +++ ftp.app-0.6/debian/FTP.1 2017-09-11 11:08:31.000000000 +0000 @@ -17,5 +17,5 @@ .SH AUTHOR FTP was written by Riccardo Mottola. .PP -This manual page was written by G\[:u]rkan Seng\[:u]n , +This manual page was written by G\[:u]rkan Myczko , for the Debian project (but may be used by others). diff -Nru ftp.app-0.5/English.lproj/GetName.nib/classes.nib ftp.app-0.6/English.lproj/GetName.nib/classes.nib --- ftp.app-0.5/English.lproj/GetName.nib/classes.nib 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/English.lproj/GetName.nib/classes.nib 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ -{ - IBClasses = ( - {CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; }, - { - ACTIONS = {cancelPressed = id; okPressed = id; }; - CLASS = GetNameController; - LANGUAGE = ObjC; - OUTLETS = {messageField = NSTextField; panel = NSPanel; textField = NSTextField; }; - SUPERCLASS = NSObject; - } - ); - IBVersion = 1; -} \ No newline at end of file diff -Nru ftp.app-0.5/English.lproj/GetName.nib/info.nib ftp.app-0.6/English.lproj/GetName.nib/info.nib --- ftp.app-0.5/English.lproj/GetName.nib/info.nib 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/English.lproj/GetName.nib/info.nib 1970-01-01 00:00:00.000000000 +0000 @@ -1,18 +0,0 @@ - - - - - IBDocumentLocation - 168 85 356 240 0 0 1440 938 - IBFramework Version - 489.0 - IBOldestOS - 1 - IBOpenObjects - - 6 - - IBSystem Version - 8S165 - - Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/English.lproj/GetName.nib/keyedobjects.nib and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/English.lproj/GetName.nib/keyedobjects.nib differ Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/English.lproj/GetName.nib/objects.nib and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/English.lproj/GetName.nib/objects.nib differ Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/English.lproj/InfoPlist.strings and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/English.lproj/InfoPlist.strings differ diff -Nru ftp.app-0.5/English.lproj/MainMenu.nib/classes.nib ftp.app-0.6/English.lproj/MainMenu.nib/classes.nib --- ftp.app-0.5/English.lproj/MainMenu.nib/classes.nib 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/English.lproj/MainMenu.nib/classes.nib 1970-01-01 00:00:00.000000000 +0000 @@ -1,58 +0,0 @@ -{ - IBClasses = ( - { - ACTIONS = { - anonymousConn = id; - cancelConn = id; - changePathFromMenu = id; - connectConn = id; - disconnect = id; - downloadButton = id; - listDoubleClick = id; - localDelete = id; - localNewFolder = id; - localRefresh = id; - localRename = id; - prefCancel = id; - prefSave = id; - remoteDelete = id; - remoteNewFolder = id; - remoteRefresh = id; - remoteRename = id; - showConnPanel = id; - showFtpLog = id; - showPrefPanel = id; - uploadButton = id; - }; - CLASS = AppController; - LANGUAGE = ObjC; - OUTLETS = { - buttDownload = NSButton; - buttUpload = NSButton; - connAddress = NSTextField; - connAnon = NSButton; - connPass = NSTextField; - connPort = NSTextField; - connUser = NSTextField; - connectPanel = NSPanel; - infoMessage = NSTextField; - infoSize = NSTextField; - infoSpeed = NSTextField; - localPath = NSPopUpButton; - localView = NSTableView; - logTextField = NSTextView; - logWin = NSWindow; - mainWin = NSWindow; - portType = NSMatrix; - prefPanel = NSPanel; - progBar = NSProgressIndicator; - remotePath = NSPopUpButton; - remoteView = NSTableView; - }; - SUPERCLASS = NSObject; - }, - {CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; }, - {CLASS = fileTransmitParms; LANGUAGE = ObjC; SUPERCLASS = NSObject; } - ); - IBVersion = 1; -} \ No newline at end of file diff -Nru ftp.app-0.5/English.lproj/MainMenu.nib/info.nib ftp.app-0.6/English.lproj/MainMenu.nib/info.nib --- ftp.app-0.5/English.lproj/MainMenu.nib/info.nib 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/English.lproj/MainMenu.nib/info.nib 1970-01-01 00:00:00.000000000 +0000 @@ -1,27 +0,0 @@ - - - - - IBDocumentLocation - 68 91 356 240 0 0 1440 938 - IBEditorPositions - - 29 - 194 678 369 44 0 0 1440 938 - - IBFramework Version - 489.0 - IBOldestOS - 1 - IBOpenObjects - - 274 - 206 - 29 - 21 - 218 - - IBSystem Version - 8S165 - - Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/English.lproj/MainMenu.nib/keyedobjects.nib and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/English.lproj/MainMenu.nib/keyedobjects.nib differ Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/English.lproj/MainMenu.nib/objects.nib and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/English.lproj/MainMenu.nib/objects.nib differ diff -Nru ftp.app-0.5/fileElement.h ftp.app-0.6/fileElement.h --- ftp.app-0.5/fileElement.h 2014-05-24 20:30:51.000000000 +0000 +++ ftp.app-0.6/fileElement.h 2016-08-02 21:06:32.000000000 +0000 @@ -1,7 +1,7 @@ /* Project: FTP - Copyright (C) 2005-2013 Riccardo Mottola + Copyright (C) 2005-2016 Riccardo Mottola Author: Riccardo Mottola @@ -42,6 +42,7 @@ - (id)initWithPath:(NSString *)path andAttributes:(NSDictionary *)attribs; - (id)initWithLsLine :(char *)line; +- (NSDictionary *)attributes; - (NSString *)name; - (void)setName: (NSString *)n; - (NSString *)path; @@ -49,6 +50,7 @@ - (NSString *)linkTargetName; - (BOOL)isDir; - (BOOL)isLink; +- (void)setIsLink:(BOOL)flag; - (unsigned long long)size; @end diff -Nru ftp.app-0.5/fileElement.m ftp.app-0.6/fileElement.m --- ftp.app-0.5/fileElement.m 2014-05-24 20:30:51.000000000 +0000 +++ ftp.app-0.6/fileElement.m 2017-03-15 16:50:09.000000000 +0000 @@ -1,7 +1,7 @@ /* Project: FTP - Copyright (C) 2005-2013 Riccardo Mottola + Copyright (C) 2005-2017 Riccardo Mottola Author: Riccardo Mottola @@ -33,9 +33,46 @@ { [fileName release]; [filePath release]; + [linkTargetName release]; + [modifDate release]; [super dealloc]; } +/* -- coder methods for copying -- */ +- (Class) classForCoder +{ + return [FileElement class]; +} + +- (id) replacementObjectForPortCoder: (NSPortCoder*)aCoder +{ + return self; +} + +- (void) encodeWithCoder: (NSCoder*)aCoder +{ + [aCoder encodeObject: fileName]; + [aCoder encodeObject: filePath]; + [aCoder encodeObject: linkTargetName]; + [aCoder encodeValueOfObjCType: @encode(BOOL) at: &isDir]; + [aCoder encodeValueOfObjCType: @encode(BOOL) at: &isLink]; + [aCoder encodeValueOfObjCType: @encode(unsigned long long) at: &size]; + [aCoder encodeObject: modifDate]; +} + +- (id) initWithCoder: (NSCoder*)aCoder +{ + self = [super init]; + fileName = [[aCoder decodeObject] retain]; + filePath = [[aCoder decodeObject] retain]; + linkTargetName = [[aCoder decodeObject] retain]; + [aCoder decodeValueOfObjCType: @encode(BOOL) at: &isDir]; + [aCoder decodeValueOfObjCType: @encode(BOOL) at: &isLink]; + [aCoder decodeValueOfObjCType: @encode(unsigned long long) at: &size]; + modifDate = [[aCoder decodeObject] retain]; + return self; +} + /* initialize a file element using attrbutes of NSFileManager */ @@ -57,6 +94,23 @@ return self; } +- (NSDictionary *)attributes +{ + NSMutableDictionary *attr; + + attr = [[NSMutableDictionary alloc] init]; + [attr setObject:[NSNumber numberWithLongLong:size] forKey:NSFileSize]; + if (modifDate) + [attr setObject:modifDate forKey:NSFileModificationDate]; + if (isDir) + [attr setObject:NSFileTypeDirectory forKey:NSFileType]; + else + [attr setObject:NSFileTypeRegular forKey:NSFileType]; + + [attr autorelease]; + return [NSDictionary dictionaryWithDictionary:attr]; +} + /* as a parser aid, check if a string is a month */ - (int)checkMonth: (NSString *)token { @@ -189,7 +243,7 @@ while ([fullLine characterAtIndex:cursor] == ' ' && cursor <= lineLen) cursor++; - // typically links - user - group - size + // typically links - (user) - group - size searchRange = NSMakeRange(cursor, lineLen-cursor); tokenEnd = [fullLine rangeOfCharacterFromSet:whiteSet options:0 range:searchRange]; @@ -279,63 +333,67 @@ } elementsFound = [splitLine count]; + // If the listing had only 8 elements out of 9 + // Missing user is supposed and a blank is inserted + if (elementsFound == 8) + { + [splitLine insertObject: @"" atIndex:2]; + foundStandardMonth = foundOneBeforeMonth; + elementsFound = [splitLine count]; + } - // copy back the found data + // Parse split data if (foundStandardMonth && elementsFound == 9) - { - NSRange linkArrowRange; + { + NSRange linkArrowRange; + NSString *tmpFileName; + NSString *tmpSizeString; // everything is fine and ok, we have a full-blown listing and parsed it well; isDir = NO; + isLink = NO; if ([[splitLine objectAtIndex:0] characterAtIndex:0] == 'd') isDir = YES; - [[NSScanner scannerWithString: [splitLine objectAtIndex:4]] scanLongLong:&tempLL]; - if (tempLL > 0) - size = (unsigned long long)tempLL; - else - size = 0; - linkArrowRange = [[splitLine objectAtIndex:8] rangeOfString: @" -> "]; - if (linkArrowRange.location == NSNotFound) - { - fileName = [[splitLine objectAtIndex:8] retain]; - } - else - { + else if ([[splitLine objectAtIndex:0] characterAtIndex:0] == 'l') isLink = YES; - size = 0; - fileName = [[[splitLine objectAtIndex:8] substringToIndex: linkArrowRange.location] retain]; - linkTargetName = [[[splitLine objectAtIndex:8] substringFromIndex: linkArrowRange.location+linkArrowRange.length] retain]; - NSLog(@"we have a link (1) %@", linkTargetName); - } - } - else if (foundOneBeforeMonth && elementsFound == 8) - { - NSRange linkArrowRange; - - // we miss the link count or user probably - isDir = NO; - if ([[splitLine objectAtIndex:0] characterAtIndex:0] == 'd') - isDir = YES; - [[NSScanner scannerWithString: [splitLine objectAtIndex:3]] scanLongLong:&tempLL]; + + size = 0; + tmpSizeString = [splitLine objectAtIndex:4]; + [[NSScanner scannerWithString: tmpSizeString] scanLongLong:&tempLL]; if (tempLL > 0) size = (unsigned long long)tempLL; - else - size = 0; - linkArrowRange = [[splitLine objectAtIndex:7] rangeOfString: @" -> "]; - if (linkArrowRange.location == NSNotFound) - { - fileName = [[splitLine objectAtIndex:7] retain]; - } - else - { - isLink = YES; - size = 0; - fileName = [[[splitLine objectAtIndex:7] substringToIndex: linkArrowRange.location] retain]; - linkTargetName = [[[splitLine objectAtIndex:7] substringFromIndex: linkArrowRange.location+linkArrowRange.length] retain]; - NSLog(@"we have a link (2) %@", linkTargetName); - } - } else - return nil; + + tmpFileName = [splitLine objectAtIndex:elementsFound -1]; + linkArrowRange = [tmpFileName rangeOfString: @" -> "]; + if (isLink) + { + if (linkArrowRange.location == NSNotFound) + { + NSLog(@"we have a link, but no target to parse: %@", tmpFileName); + fileName = [tmpFileName retain]; + } + else + { + fileName = [[tmpFileName substringToIndex: linkArrowRange.location] retain]; + linkTargetName = [[tmpFileName substringFromIndex: linkArrowRange.location+linkArrowRange.length] retain]; + NSLog(@"we have a link, target: %@", linkTargetName); + } + // we suppose that files have extensions, dirs not + // links have no further information + if ([[fileName pathExtension] isEqualToString:@""]) + { + NSLog(@"we suppose %@ is a dir", fileName); + isDir = YES; + } + } + else + { + fileName = [tmpFileName retain]; + + } + } + else + return nil; } else if ((fullLine != NULL) && ([fullLine rangeOfString: @"*FILE"].location != NSNotFound)) { @@ -422,12 +480,6 @@ return nil; else if([fileName isEqualToString:@".."]) return nil; - - if (isLink) - { - NSLog(@"size: %llu", size); - NSLog(@"filename: %@", fileName); - } } return self; } @@ -478,6 +530,11 @@ return isLink; } +- (void)setIsLink:(BOOL)flag +{ + isLink = flag; +} + - (unsigned long long)size { return size; diff -Nru ftp.app-0.5/fileTable.h ftp.app-0.6/fileTable.h --- ftp.app-0.5/fileTable.h 2015-02-16 23:51:38.000000000 +0000 +++ ftp.app-0.6/fileTable.h 2017-01-19 09:34:43.000000000 +0000 @@ -1,7 +1,7 @@ /* Project: FTP - Copyright (C) 2005-2015 Riccardo Mottola + Copyright (C) 2005-2016 Riccardo Mottola Author: Riccardo Mottola @@ -58,7 +58,6 @@ - (FileElement *)elementAtIndex:(NSUInteger)index; - (void)generateSortedArray; - (void)addObject:(FileElement *)object; -- (void)removeObjectAtIndex:(NSUInteger)index; - (void)removeObject:(FileElement *)object; - (void)sortByIdent:(NSString *)idStr; - (BOOL)containsFileName:(NSString *)name; diff -Nru ftp.app-0.5/fileTable.m ftp.app-0.6/fileTable.m --- ftp.app-0.5/fileTable.m 2015-02-16 23:51:37.000000000 +0000 +++ ftp.app-0.6/fileTable.m 2017-01-19 09:34:43.000000000 +0000 @@ -1,7 +1,7 @@ /* Project: FTP - Copyright (C) 2005-2015 Riccardo Mottola + Copyright (C) 2005-2016 Riccardo Mottola Author: Riccardo Mottola @@ -28,16 +28,17 @@ #import "fileElement.h" #import "AppController.h" -/* we sort the already existing sorted array which contains only the keys to sort on */ -NSComparisonResult compareDictElements(id e1, id e2, void *context) +/* The sortedArray is just an array of pointers to the original unsorted file elements */ +NSComparisonResult compareFileStructs(id e1, id e2, void *context) { + NSString *s1; NSString *s2; NSComparisonResult r; enum sortOrderDef sortOrder; - s1 = [(NSDictionary *)e1 objectForKey: @"name"]; - s2 = [(NSDictionary *)e2 objectForKey: @"name"]; + s1 = [(FileElement *)e1 name]; + s2 = [(FileElement *)e2 name]; sortOrder = *(enum sortOrderDef *)context; r = [s1 compare: s2]; @@ -91,45 +92,27 @@ [sortedArray removeAllObjects]; for (i = 0; i < [fileStructs count]; i++) { - NSNumber *n; - NSMutableDictionary *dict; FileElement *fe; fe = [fileStructs objectAtIndex: i]; - n = [NSNumber numberWithInt: i]; - dict = [NSMutableDictionary dictionary]; - [dict setObject: [fe name] forKey: @"name"]; - [dict setObject: n forKey: @"row"]; - [sortedArray addObject: dict]; + [sortedArray addObject: fe]; } } + - (void)addObject:(FileElement *)object { /* add the file element to the storage */ [fileStructs addObject:object]; /* keep the sorting map array in sync */ - [self generateSortedArray]; + [sortedArray addObject:object]; if (sortOrder != undefined) { - [sortedArray sortUsingFunction:compareDictElements context:&sortOrder]; + [sortedArray sortUsingFunction:compareFileStructs context:&sortOrder]; } } -- (void)removeObjectAtIndex:(NSUInteger)index -{ - NSUInteger originalRow; - - originalRow = (NSUInteger)[[[sortedArray objectAtIndex: index] objectForKey: @"row"] intValue]; - - [fileStructs removeObjectAtIndex:originalRow]; - [self generateSortedArray]; - if (sortOrder != undefined) - { - [sortedArray sortUsingFunction:compareDictElements context:&sortOrder]; - } -} - (void)removeObject:(FileElement *)object { @@ -144,22 +127,20 @@ /* remove object from storage */ [fileStructs removeObject:object]; + index = [sortedArray indexOfObject:object]; + if (index != NSNotFound) + [sortedArray removeObjectAtIndex:index]; - [self generateSortedArray]; if (sortOrder != undefined) { - [sortedArray sortUsingFunction:compareDictElements context:&sortOrder]; + [sortedArray sortUsingFunction:compareFileStructs context:&sortOrder]; } } /** returns the object after resolving sorting */ - (FileElement *)elementAtIndex:(NSUInteger)index { - NSUInteger originalRow; - - originalRow = (NSUInteger)[[[sortedArray objectAtIndex: index] objectForKey: @"row"] intValue]; - - return [fileStructs objectAtIndex:originalRow]; + return [sortedArray objectAtIndex:index]; } - (void)sortByIdent:(NSString *)idStr @@ -177,7 +158,7 @@ sortOrder = ascending; } sortByIdent = idStr; - [sortedArray sortUsingFunction:compareDictElements context:&sortOrder]; + [sortedArray sortUsingFunction:compareFileStructs context:&sortOrder]; } @@ -191,13 +172,11 @@ - (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(NSInteger)rowIndex { id theElement; - NSInteger originalRow; theElement = NULL; NSParameterAssert(rowIndex >= 0 && rowIndex < [sortedArray count]); - originalRow = [[[sortedArray objectAtIndex: rowIndex] objectForKey: @"row"] intValue]; if ([[aTableColumn identifier] isEqualToString:TAG_FILENAME]) - theElement = [[fileStructs objectAtIndex:originalRow] name]; + theElement = [[sortedArray objectAtIndex:rowIndex] name]; else NSLog(@"unknown table column ident"); return theElement; diff -Nru ftp.app-0.5/ftpclient.h ftp.app-0.6/ftpclient.h --- ftp.app-0.5/ftpclient.h 2015-02-16 23:51:38.000000000 +0000 +++ ftp.app-0.6/ftpclient.h 2016-08-08 21:32:39.000000000 +0000 @@ -97,7 +97,9 @@ - (int)writeLine:(NSString *)line; - (int)writeLine:(NSString *)line byLoggingIt:(BOOL)doLog; +- (oneway void)retrieveFile:(FileElement *)file to:(LocalClient *)localClient; - (BOOL)retrieveFile:(FileElement *)file to:(LocalClient *)localClient beingAt:(int)depth; +- (oneway void)storeFile:(FileElement *)file from:(LocalClient *)localClient; - (BOOL)storeFile:(FileElement *)file from:(LocalClient *)localClient beingAt:(int)depth; - (int)connect:(int)port :(char *)server; diff -Nru ftp.app-0.5/ftpclient.m ftp.app-0.6/ftpclient.m --- ftp.app-0.5/ftpclient.m 2015-02-16 23:51:37.000000000 +0000 +++ ftp.app-0.6/ftpclient.m 2017-07-28 10:44:57.000000000 +0000 @@ -1,7 +1,7 @@ /* Project: FTP - Copyright (C) 2005-2015 Riccardo Mottola + Copyright (C) 2005-2017 Riccardo Mottola Author: Riccardo Mottola @@ -55,7 +55,7 @@ #define MAX_CONTROL_BUFF 2048 #define MAX_DATA_BUFF 2048 -#if defined(__linux__) || defined (__BSD_VISIBLE) +#if defined(__linux__) || defined (__BSD_VISIBLE) || defined (NetBSD) || defined (__APPLE__) #define socklentype socklen_t #else #define socklentype int @@ -395,6 +395,15 @@ return retVal; } +- (oneway void)retrieveFile:(FileElement *)file to:(LocalClient *)localClient +{ + BOOL gotFile; + + gotFile = [self retrieveFile:file to:localClient beingAt:0]; + + [controller fileRetrieved:gotFile]; +} + - (BOOL)retrieveFile:(FileElement *)file to:(LocalClient *)localClient beingAt:(int)depth; { NSString *fileName; @@ -474,8 +483,16 @@ if(replyCode != 150) { - [controller showAlertDialog:@"Unexpected server error."]; - NSLog(@"Unexpected condition in retrieve"); + if (replyCode >= 400) + { + [controller showAlertDialog:[reply objectAtIndex:0]]; + [self logIt: [reply objectAtIndex:0]]; + } + else + { + [controller showAlertDialog:@"Unexpected server error."]; + NSLog(@"Unexpected condition in retrieve"); + } return NO; /* we have an error or some unexpected condition */ } else @@ -521,7 +538,7 @@ return NO; } - localFileStream = fopen([localPath cString], "w"); + localFileStream = fopen([localPath cString], "wb"); if (localFileStream == NULL) { [controller showAlertDialog:@"Opening of local file failed.\nCheck permissions and free space."]; @@ -532,7 +549,6 @@ totalBytes = 0; progressIncBytes = 0; gotFile = NO; - [controller setThreadRunningState:YES]; [controller setTransferBegin:fileName :fileSize]; while (!gotFile) { @@ -565,8 +581,17 @@ [self closeDataStream]; [self readReply:&reply]; [reply release]; - [controller setThreadRunningState:NO]; - return gotFile; + + return gotFile; +} + +- (oneway void)storeFile:(FileElement *)file from:(LocalClient *)localClient +{ + BOOL gotFile; + + gotFile = [self storeFile:file from:localClient beingAt:0]; + + [controller fileStored:gotFile]; } - (BOOL)storeFile:(FileElement *)file from:(LocalClient *)localClient beingAt:(int)depth @@ -649,7 +674,7 @@ replyCode = [self readReply:&reply]; NSLog(@"%d reply is %@: ", replyCode, [reply objectAtIndex:0]); - if (replyCode >= 550 && replyCode <= 559) + if (replyCode >= 400 && replyCode <= 559) { [controller showAlertDialog:[reply objectAtIndex:0]]; [self logIt: [reply objectAtIndex:0]]; @@ -666,10 +691,10 @@ } - localFileStream = fopen([localPath cString], "r"); + localFileStream = fopen([localPath cString], "rb"); if (localFileStream == NULL) { - [controller showAlertDialog:@"Opening of local file failed.\n Check permissions."]; + [controller showAlertDialog:@"Opening of local file failed.\nCheck permissions."]; perror("local fopen failed"); return NO; } @@ -677,7 +702,6 @@ totalBytes = 0; progressIncBytes = 0; gotFile = NO; - [controller setThreadRunningState:YES]; [controller setTransferBegin:fileName :fileSize]; while (!gotFile) { @@ -691,9 +715,11 @@ NSLog(@"feof"); } else { - if (write(localSocket, buff, bytesRead) < bytesRead) + int sentBytes; + + if ((sentBytes = send(localSocket, buff, bytesRead, 0)) < bytesRead) { - NSLog(@"socket write error, store file"); + NSLog(@"socket write error, store file. Wrote %d of %d", sentBytes, bytesRead); } totalBytes += bytesRead; progressIncBytes += bytesRead; @@ -710,11 +736,10 @@ [self closeDataStream]; [self readReply:&reply]; [reply release]; - [controller setThreadRunningState:NO]; return gotFile; } -- (void)deleteFile:(FileElement *)file beingAt:(int)depth +- (BOOL)deleteFile:(FileElement *)file beingAt:(int)depth { NSString *fileName; NSString *command; @@ -734,7 +759,7 @@ if (depth > 3) { NSLog(@"Max depth reached: %d", depth); - return; + return NO; } pristineRemotePath = [[self workingDir] retain]; @@ -761,8 +786,16 @@ [self writeLine:command]; replyCode = [self readReply:&reply]; NSLog(@"%d reply is %@: ", replyCode, [reply objectAtIndex:0]); - [reply release]; + if(replyCode >= 400) + { + [controller showAlertDialog:[reply objectAtIndex:0]]; + [self logIt: [reply objectAtIndex:0]]; + [reply release]; + return NO; /* we have an error or some unexpected condition */ + } + [reply release]; + return YES; } /* initialize a connection */ @@ -893,9 +926,7 @@ - (int)initDataConn { socklentype addrLen; /* socklen_t on some systems ? */ - int socketReuse; - - socketReuse = YES; + const int socketReuse = 1; /* passive mode */ if (usesPassive) @@ -993,11 +1024,11 @@ /* linux is happier if we set both ends that way */ if (usesPorts == NO) { - if (setsockopt(dataSocket, SOL_SOCKET, SO_REUSEADDR, &socketReuse, sizeof (socketReuse)) < 0) + if (setsockopt(dataSocket, SOL_SOCKET, SO_REUSEADDR, &socketReuse, (socklentype) sizeof (socketReuse)) < 0) { perror("ftpclient: setsockopt (reuse address) on data"); } - if (setsockopt(controlSocket, SOL_SOCKET, SO_REUSEADDR, &socketReuse, sizeof (socketReuse)) < 0) + if (setsockopt(controlSocket, SOL_SOCKET, SO_REUSEADDR, &socketReuse, (socklentype) sizeof (socketReuse)) < 0) { perror("ftpclient: setsockopt (reuse address) on control"); } @@ -1046,8 +1077,10 @@ tempStr = [NSString stringWithFormat:@"PORT %u,%u,%u,%u,%u,%u", addr.ipv4[0], addr.ipv4[1], addr.ipv4[2], addr.ipv4[3], p1, p2]; [self writeLine:tempStr]; NSLog(@"port str: %@", tempStr); - if ((returnCode = [self readReply:&reply]) != 200) + returnCode = [self readReply:&reply]; + if (returnCode != 200) { + NSLog(@"Error return code of PORT: %d", returnCode); if(reply && [reply count] > 0) { NSLog(@"error occoured in port command: %@", [reply objectAtIndex:0]); @@ -1075,16 +1108,11 @@ if ((localSocket = accept(dataSocket, &from, &fromLen)) < 0) { perror("accepting socket, initDataStream: "); + return -1; } initStream(&dataStream, localSocket); } -/* - if (dataStream == NULL) - { - perror("data stream opening failed"); - return -1; - } */ - NSLog(@"data stream open"); + return 0; } @@ -1141,7 +1169,7 @@ /* RM again: a better path limit is needed */ -- (NSArray *)dirContents +- (bycopy NSArray *)dirContents { int ch; char buff[MAX_DATA_BUFF]; diff -Nru ftp.app-0.5/FTPInfo.plist ftp.app-0.6/FTPInfo.plist --- ftp.app-0.5/FTPInfo.plist 2015-03-02 19:24:30.000000000 +0000 +++ ftp.app-0.6/FTPInfo.plist 2017-07-28 10:13:58.000000000 +0000 @@ -2,13 +2,14 @@ ApplicationDescription = "FTP client"; ApplicationIcon = "FTP_icon_gs.tif"; ApplicationName = FTP; - ApplicationRelease = "0.5"; + ApplicationRelease = "0.6"; Authors = ( "Riccardo Mottola " ); - Copyright = "Copyright (C) 2005-2015"; - CopyrightDescription = "Released under GPL"; - FullVersionID = "0.5"; + CFBundleIdentifier = "org.gap.FTP"; + Copyright = "Copyright (C) 2005-2017"; + CopyrightDescription = "Released under GPL v2+"; + FullVersionID = "0.6"; NSExecutable = FTP; NSIcon = "FTP_icon_gs.tif"; NSMainNibFile = "FTP.gorm"; diff -Nru ftp.app-0.5/FTP-T.xcodeproj/project.pbxproj ftp.app-0.6/FTP-T.xcodeproj/project.pbxproj --- ftp.app-0.5/FTP-T.xcodeproj/project.pbxproj 2014-05-24 20:30:51.000000000 +0000 +++ ftp.app-0.6/FTP-T.xcodeproj/project.pbxproj 2017-01-19 09:34:43.000000000 +0000 @@ -9,15 +9,16 @@ /* Begin PBXBuildFile section */ 8531288D1767CADA00F56C92 /* GetNameController.h in Headers */ = {isa = PBXBuildFile; fileRef = 8531288B1767CADA00F56C92 /* GetNameController.h */; }; 8531288E1767CADB00F56C92 /* GetNameController.m in Sources */ = {isa = PBXBuildFile; fileRef = 8531288C1767CADA00F56C92 /* GetNameController.m */; }; - 853128941767CC2600F56C92 /* GetName.nib in Resources */ = {isa = PBXBuildFile; fileRef = 853128921767CC2600F56C92 /* GetName.nib */; }; + 85D3CFE11D99296E00679061 /* MainMenu.nib in Resources */ = {isa = PBXBuildFile; fileRef = 29B97319FDCFA39411CA2CEA /* MainMenu.nib */; }; + 85D3CFEB1D992A2200679061 /* GetName.nib in Resources */ = {isa = PBXBuildFile; fileRef = 853128931767CC2600F56C92 /* GetName.nib */; }; + 85D3CFEE1D992B2C00679061 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = 85D3CFEC1D992B2C00679061 /* Localizable.strings */; }; + 85D3CFF81D992BB100679061 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C165DFE840E0CC02AAC07 /* InfoPlist.strings */; }; 85E8F2AD16EFCF6C00E03CA9 /* AppController.h in Headers */ = {isa = PBXBuildFile; fileRef = F5F5F93707FD8CAD01A80101 /* AppController.h */; }; 85E8F2AE16EFCF6C00E03CA9 /* ftpclient.h in Headers */ = {isa = PBXBuildFile; fileRef = F5F5F93907FD8CAD01A80101 /* ftpclient.h */; }; 85E8F2AF16EFCF6C00E03CA9 /* localclient.h in Headers */ = {isa = PBXBuildFile; fileRef = F56A03FD080AC71101A80101 /* localclient.h */; }; 85E8F2B016EFCF6C00E03CA9 /* fileTable.h in Headers */ = {isa = PBXBuildFile; fileRef = F5BE3AF6080C6A3601A80101 /* fileTable.h */; }; 85E8F2B116EFCF6C00E03CA9 /* fileElement.h in Headers */ = {isa = PBXBuildFile; fileRef = F5C84D6008142DF201A80101 /* fileElement.h */; }; 85E8F2B216EFCF6C00E03CA9 /* client.h in Headers */ = {isa = PBXBuildFile; fileRef = F5EFB6470818FE6E01A80101 /* client.h */; }; - 85E8F2B416EFCF6C00E03CA9 /* MainMenu.nib in Resources */ = {isa = PBXBuildFile; fileRef = 29B97318FDCFA39411CA2CEA /* MainMenu.nib */; }; - 85E8F2B516EFCF6C00E03CA9 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */; }; 85E8F2B616EFCF6C00E03CA9 /* arrow_right.tiff in Resources */ = {isa = PBXBuildFile; fileRef = F5C0879F08A0C47B01A8012F /* arrow_right.tiff */; }; 85E8F2B716EFCF6C00E03CA9 /* arrow_left.tiff in Resources */ = {isa = PBXBuildFile; fileRef = F5C087A108A0C4AF01A8012F /* arrow_left.tiff */; }; 85E8F2B816EFCF6C00E03CA9 /* FTP_icon_osx.icns in Resources */ = {isa = PBXBuildFile; fileRef = 85FC29710DD7B28300A80101 /* FTP_icon_osx.icns */; }; @@ -34,16 +35,19 @@ /* End PBXBuildFile section */ /* Begin PBXFileReference section */ - 089C165DFE840E0CC02AAC07 /* English */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = ""; }; + 089C165DFE840E0CC02AAC07 /* InfoPlist.strings */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = InfoPlist.strings; path = Resources/InfoPlist.strings; sourceTree = ""; }; 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = /System/Library/Frameworks/Cocoa.framework; sourceTree = ""; }; 29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; - 29B97319FDCFA39411CA2CEA /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = English.lproj/MainMenu.nib; sourceTree = ""; }; + 29B97319FDCFA39411CA2CEA /* MainMenu.nib */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = MainMenu.nib; path = Resources/MainMenu.nib; sourceTree = ""; }; 29B97324FDCFA39411CA2CEA /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; }; 29B97325FDCFA39411CA2CEA /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; }; 8531288B1767CADA00F56C92 /* GetNameController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = GetNameController.h; sourceTree = ""; }; 8531288C1767CADA00F56C92 /* GetNameController.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = GetNameController.m; sourceTree = ""; }; - 853128931767CC2600F56C92 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = English.lproj/GetName.nib; sourceTree = ""; }; + 853128931767CC2600F56C92 /* GetName.nib */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = GetName.nib; path = Resources/GetName.nib; sourceTree = ""; }; 853FB7F814A3F52200DE7B18 /* README */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = README; sourceTree = ""; }; + 85D3CFED1D992B2C00679061 /* English */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.plist.strings; name = English; path = Resources/English.lproj/Localizable.strings; sourceTree = ""; }; + 85D3CFEF1D992B3A00679061 /* German */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = German; path = Resources/German.lproj/Localizable.strings; sourceTree = ""; }; + 85D3CFF01D992B4000679061 /* Italian */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = Italian; path = Resources/Italian.lproj/Localizable.strings; sourceTree = ""; }; 85E8F2C916EFCF6C00E03CA9 /* FTP.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = FTP.app; sourceTree = BUILT_PRODUCTS_DIR; }; 85E8F32416EFD9D000E03CA9 /* ChangeLog */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = ChangeLog; sourceTree = ""; }; 85FC29710DD7B28300A80101 /* FTP_icon_osx.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = FTP_icon_osx.icns; sourceTree = ""; }; @@ -144,12 +148,13 @@ 29B97317FDCFA39411CA2CEA /* Resources */ = { isa = PBXGroup; children = ( - 853128921767CC2600F56C92 /* GetName.nib */, + 85D3CFEC1D992B2C00679061 /* Localizable.strings */, + 853128931767CC2600F56C92 /* GetName.nib */, 85E8F32416EFD9D000E03CA9 /* ChangeLog */, 853FB7F814A3F52200DE7B18 /* README */, 85FC29710DD7B28300A80101 /* FTP_icon_osx.icns */, - 29B97318FDCFA39411CA2CEA /* MainMenu.nib */, - 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */, + 29B97319FDCFA39411CA2CEA /* MainMenu.nib */, + 089C165DFE840E0CC02AAC07 /* InfoPlist.strings */, F5C0879F08A0C47B01A8012F /* arrow_right.tiff */, F5C087A108A0C4AF01A8012F /* arrow_left.tiff */, ); @@ -210,9 +215,18 @@ 29B97313FDCFA39411CA2CEA /* Project object */ = { isa = PBXProject; buildConfigurationList = 85A6DBE310D43D010048FE0B /* Build configuration list for PBXProject "FTP-T" */; + compatibilityVersion = "Xcode 2.4"; hasScannedForEncodings = 1; + knownRegions = ( + English, + Japanese, + French, + German, + Italian, + ); mainGroup = 29B97314FDCFA39411CA2CEA /* FTP */; projectDirPath = ""; + projectRoot = ""; targets = ( 85E8F2AB16EFCF6C00E03CA9 /* FTP */, ); @@ -224,14 +238,15 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( - 85E8F2B416EFCF6C00E03CA9 /* MainMenu.nib in Resources */, - 85E8F2B516EFCF6C00E03CA9 /* InfoPlist.strings in Resources */, + 85D3CFE11D99296E00679061 /* MainMenu.nib in Resources */, + 85D3CFF81D992BB100679061 /* InfoPlist.strings in Resources */, 85E8F2B616EFCF6C00E03CA9 /* arrow_right.tiff in Resources */, 85E8F2B716EFCF6C00E03CA9 /* arrow_left.tiff in Resources */, 85E8F2B816EFCF6C00E03CA9 /* FTP_icon_osx.icns in Resources */, 85E8F2B916EFCF6C00E03CA9 /* README in Resources */, 85E8F32516EFD9D000E03CA9 /* ChangeLog in Resources */, - 853128941767CC2600F56C92 /* GetName.nib in Resources */, + 85D3CFEB1D992A2200679061 /* GetName.nib in Resources */, + 85D3CFEE1D992B2C00679061 /* Localizable.strings in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -256,28 +271,14 @@ /* End PBXSourcesBuildPhase section */ /* Begin PBXVariantGroup section */ - 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */ = { - isa = PBXVariantGroup; - children = ( - 089C165DFE840E0CC02AAC07 /* English */, - ); - name = InfoPlist.strings; - sourceTree = ""; - }; - 29B97318FDCFA39411CA2CEA /* MainMenu.nib */ = { - isa = PBXVariantGroup; - children = ( - 29B97319FDCFA39411CA2CEA /* English */, - ); - name = MainMenu.nib; - sourceTree = ""; - }; - 853128921767CC2600F56C92 /* GetName.nib */ = { + 85D3CFEC1D992B2C00679061 /* Localizable.strings */ = { isa = PBXVariantGroup; children = ( - 853128931767CC2600F56C92 /* English */, + 85D3CFED1D992B2C00679061 /* English */, + 85D3CFEF1D992B3A00679061 /* German */, + 85D3CFF01D992B4000679061 /* Italian */, ); - name = GetName.nib; + name = Localizable.strings; sourceTree = ""; }; /* End PBXVariantGroup section */ diff -Nru ftp.app-0.5/FTP.xcode/project.pbxproj ftp.app-0.6/FTP.xcode/project.pbxproj --- ftp.app-0.5/FTP.xcode/project.pbxproj 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/FTP.xcode/project.pbxproj 2017-01-19 09:34:42.000000000 +0000 @@ -27,24 +27,6 @@ refType = 4; sourceTree = ""; }; - 089C165CFE840E0CC02AAC07 = { - children = ( - 089C165DFE840E0CC02AAC07, - ); - isa = PBXVariantGroup; - name = InfoPlist.strings; - refType = 4; - sourceTree = ""; - }; - 089C165DFE840E0CC02AAC07 = { - fileEncoding = 10; - isa = PBXFileReference; - lastKnownFileType = text.plist.strings; - name = English; - path = English.lproj/InfoPlist.strings; - refType = 4; - sourceTree = ""; - }; //080 //081 //082 @@ -120,6 +102,13 @@ ); hasScannedForEncodings = 1; isa = PBXProject; + knownRegions = ( + English, + Japanese, + French, + German, + Italian, + ); mainGroup = 29B97314FDCFA39411CA2CEA; projectDirPath = ""; targets = ( @@ -161,13 +150,14 @@ }; 29B97317FDCFA39411CA2CEA = { children = ( + 85848F181DBFE1F70050DC12, + 85848F121DBFE1A70050DC12, + 85848F131DBFE1A70050DC12, + 85848F141DBFE1A70050DC12, 85D69CD717651E24000AC90B, 85FC29710DD7B28300A80101, - 29B97318FDCFA39411CA2CEA, - 089C165CFE840E0CC02AAC07, F5C0879F08A0C47B01A8012F, F5C087A108A0C4AF01A8012F, - 85D69C741762961D000AC90B, ); isa = PBXGroup; name = Resources; @@ -175,24 +165,6 @@ refType = 4; sourceTree = ""; }; - 29B97318FDCFA39411CA2CEA = { - children = ( - 29B97319FDCFA39411CA2CEA, - ); - isa = PBXVariantGroup; - name = MainMenu.nib; - path = ""; - refType = 4; - sourceTree = ""; - }; - 29B97319FDCFA39411CA2CEA = { - isa = PBXFileReference; - lastKnownFileType = wrapper.nib; - name = English; - path = English.lproj/MainMenu.nib; - refType = 4; - sourceTree = ""; - }; 29B97323FDCFA39411CA2CEA = { children = ( 1058C7A0FEA54F0111CA2CBB, @@ -350,29 +322,18 @@ 8576CCEA152E1559008F8C62 = { buildActionMask = 2147483647; files = ( - 8576CCEB152E1559008F8C62, - 8576CCEC152E1559008F8C62, 8576CCED152E1559008F8C62, 8576CCEE152E1559008F8C62, 8576CCEF152E1559008F8C62, - 85D69C761762961D000AC90B, 85D69CD817651E24000AC90B, + 85848F151DBFE1A70050DC12, + 85848F161DBFE1A70050DC12, + 85848F171DBFE1A70050DC12, + 85848F1A1DBFE1F70050DC12, ); isa = PBXResourcesBuildPhase; runOnlyForDeploymentPostprocessing = 0; }; - 8576CCEB152E1559008F8C62 = { - fileRef = 29B97318FDCFA39411CA2CEA; - isa = PBXBuildFile; - settings = { - }; - }; - 8576CCEC152E1559008F8C62 = { - fileRef = 089C165CFE840E0CC02AAC07; - isa = PBXBuildFile; - settings = { - }; - }; 8576CCED152E1559008F8C62 = { fileRef = F5C0879F08A0C47B01A8012F; isa = PBXBuildFile; @@ -479,30 +440,92 @@ refType = 3; sourceTree = BUILT_PRODUCTS_DIR; }; - 85D69C741762961D000AC90B = { + 85848F121DBFE1A70050DC12 = { + isa = PBXFileReference; + lastKnownFileType = wrapper.nib; + name = GetName.nib; + path = Resources/GetName.nib; + refType = 4; + sourceTree = ""; + }; + 85848F131DBFE1A70050DC12 = { + fileEncoding = 30; + isa = PBXFileReference; + lastKnownFileType = text.plist.strings; + name = InfoPlist.strings; + path = Resources/InfoPlist.strings; + refType = 4; + sourceTree = ""; + }; + 85848F141DBFE1A70050DC12 = { + isa = PBXFileReference; + lastKnownFileType = wrapper.nib; + name = MainMenu.nib; + path = Resources/MainMenu.nib; + refType = 4; + sourceTree = ""; + }; + 85848F151DBFE1A70050DC12 = { + fileRef = 85848F121DBFE1A70050DC12; + isa = PBXBuildFile; + settings = { + }; + }; + 85848F161DBFE1A70050DC12 = { + fileRef = 85848F131DBFE1A70050DC12; + isa = PBXBuildFile; + settings = { + }; + }; + 85848F171DBFE1A70050DC12 = { + fileRef = 85848F141DBFE1A70050DC12; + isa = PBXBuildFile; + settings = { + }; + }; + 85848F181DBFE1F70050DC12 = { children = ( - 85D69C751762961D000AC90B, + 85848F191DBFE1F70050DC12, + 85848F1B1DBFE2040050DC12, + 85848F1C1DBFE20A0050DC12, ); isa = PBXVariantGroup; - name = GetName.nib; + name = Localizable.strings; path = ""; refType = 4; sourceTree = ""; }; - 85D69C751762961D000AC90B = { + 85848F191DBFE1F70050DC12 = { + fileEncoding = 30; isa = PBXFileReference; - lastKnownFileType = wrapper.nib; + lastKnownFileType = text.plist.strings; name = English; - path = English.lproj/GetName.nib; + path = Resources/English.lproj/Localizable.strings; refType = 4; sourceTree = ""; }; - 85D69C761762961D000AC90B = { - fileRef = 85D69C741762961D000AC90B; + 85848F1A1DBFE1F70050DC12 = { + fileRef = 85848F181DBFE1F70050DC12; isa = PBXBuildFile; settings = { }; }; + 85848F1B1DBFE2040050DC12 = { + isa = PBXFileReference; + lastKnownFileType = text.plist.strings; + name = German; + path = Resources/German.lproj/Localizable.strings; + refType = 4; + sourceTree = ""; + }; + 85848F1C1DBFE20A0050DC12 = { + isa = PBXFileReference; + lastKnownFileType = text.plist.strings; + name = Italian; + path = Resources/Italian.lproj/Localizable.strings; + refType = 4; + sourceTree = ""; + }; 85D69C7917629757000AC90B = { fileEncoding = 30; isa = PBXFileReference; diff -Nru ftp.app-0.5/FTP.xcodeproj/project.pbxproj ftp.app-0.6/FTP.xcodeproj/project.pbxproj --- ftp.app-0.5/FTP.xcodeproj/project.pbxproj 1970-01-01 00:00:00.000000000 +0000 +++ ftp.app-0.6/FTP.xcodeproj/project.pbxproj 2017-08-31 07:14:01.000000000 +0000 @@ -0,0 +1,411 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 42; + objects = { + +/* Begin PBXBuildFile section */ + 8531288D1767CADA00F56C92 /* GetNameController.h in Headers */ = {isa = PBXBuildFile; fileRef = 8531288B1767CADA00F56C92 /* GetNameController.h */; }; + 8531288E1767CADB00F56C92 /* GetNameController.m in Sources */ = {isa = PBXBuildFile; fileRef = 8531288C1767CADA00F56C92 /* GetNameController.m */; }; + 8534AFAA1DAB81DC005F5ECD /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = 8534AFA81DAB81DC005F5ECD /* Localizable.strings */; }; + 8570ECE01DA1916700099FC2 /* GetName.nib in Resources */ = {isa = PBXBuildFile; fileRef = 8570ECDE1DA1916700099FC2 /* GetName.nib */; }; + 8570ECE11DA1916700099FC2 /* MainMenu.nib in Resources */ = {isa = PBXBuildFile; fileRef = 8570ECDF1DA1916700099FC2 /* MainMenu.nib */; }; + 8570ECE31DA1917D00099FC2 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 8570ECE21DA1917D00099FC2 /* InfoPlist.strings */; }; + 85E8F2AD16EFCF6C00E03CA9 /* AppController.h in Headers */ = {isa = PBXBuildFile; fileRef = F5F5F93707FD8CAD01A80101 /* AppController.h */; }; + 85E8F2AE16EFCF6C00E03CA9 /* ftpclient.h in Headers */ = {isa = PBXBuildFile; fileRef = F5F5F93907FD8CAD01A80101 /* ftpclient.h */; }; + 85E8F2AF16EFCF6C00E03CA9 /* localclient.h in Headers */ = {isa = PBXBuildFile; fileRef = F56A03FD080AC71101A80101 /* localclient.h */; }; + 85E8F2B016EFCF6C00E03CA9 /* fileTable.h in Headers */ = {isa = PBXBuildFile; fileRef = F5BE3AF6080C6A3601A80101 /* fileTable.h */; }; + 85E8F2B116EFCF6C00E03CA9 /* fileElement.h in Headers */ = {isa = PBXBuildFile; fileRef = F5C84D6008142DF201A80101 /* fileElement.h */; }; + 85E8F2B216EFCF6C00E03CA9 /* client.h in Headers */ = {isa = PBXBuildFile; fileRef = F5EFB6470818FE6E01A80101 /* client.h */; }; + 85E8F2B616EFCF6C00E03CA9 /* arrow_right.tiff in Resources */ = {isa = PBXBuildFile; fileRef = F5C0879F08A0C47B01A8012F /* arrow_right.tiff */; }; + 85E8F2B716EFCF6C00E03CA9 /* arrow_left.tiff in Resources */ = {isa = PBXBuildFile; fileRef = F5C087A108A0C4AF01A8012F /* arrow_left.tiff */; }; + 85E8F2B816EFCF6C00E03CA9 /* FTP_icon_osx.icns in Resources */ = {isa = PBXBuildFile; fileRef = 85FC29710DD7B28300A80101 /* FTP_icon_osx.icns */; }; + 85E8F2B916EFCF6C00E03CA9 /* README in Resources */ = {isa = PBXBuildFile; fileRef = 853FB7F814A3F52200DE7B18 /* README */; }; + 85E8F2BB16EFCF6C00E03CA9 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 29B97316FDCFA39411CA2CEA /* main.m */; settings = {ATTRIBUTES = (); }; }; + 85E8F2BC16EFCF6C00E03CA9 /* AppController.m in Sources */ = {isa = PBXBuildFile; fileRef = F5F5F93807FD8CAD01A80101 /* AppController.m */; }; + 85E8F2BD16EFCF6C00E03CA9 /* ftpclient.m in Sources */ = {isa = PBXBuildFile; fileRef = F5F5F93A07FD8CAD01A80101 /* ftpclient.m */; }; + 85E8F2BE16EFCF6C00E03CA9 /* localclient.m in Sources */ = {isa = PBXBuildFile; fileRef = F56A03FB080AC70701A80101 /* localclient.m */; }; + 85E8F2BF16EFCF6C00E03CA9 /* fileTable.m in Sources */ = {isa = PBXBuildFile; fileRef = F5BE3AF7080C6A3601A80101 /* fileTable.m */; }; + 85E8F2C016EFCF6C00E03CA9 /* fileElement.m in Sources */ = {isa = PBXBuildFile; fileRef = F5C84D6108142DF201A80101 /* fileElement.m */; }; + 85E8F2C116EFCF6C00E03CA9 /* client.m in Sources */ = {isa = PBXBuildFile; fileRef = F5EFB6450818FE6001A80101 /* client.m */; }; + 85E8F2C316EFCF6C00E03CA9 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */; }; + 85E8F32516EFD9D000E03CA9 /* ChangeLog in Resources */ = {isa = PBXBuildFile; fileRef = 85E8F32416EFD9D000E03CA9 /* ChangeLog */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = /System/Library/Frameworks/Cocoa.framework; sourceTree = ""; }; + 29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; + 29B97324FDCFA39411CA2CEA /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; }; + 29B97325FDCFA39411CA2CEA /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; }; + 8531288B1767CADA00F56C92 /* GetNameController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = GetNameController.h; sourceTree = ""; }; + 8531288C1767CADA00F56C92 /* GetNameController.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = GetNameController.m; sourceTree = ""; }; + 8534AFA91DAB81DC005F5ECD /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = Resources/English.lproj/Localizable.strings; sourceTree = ""; }; + 8534AFAB1DAB81F5005F5ECD /* German */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = German; path = Resources/German.lproj/Localizable.strings; sourceTree = ""; }; + 8534AFAC1DAB8213005F5ECD /* Italian */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = Italian; path = Resources/Italian.lproj/Localizable.strings; sourceTree = ""; }; + 853FB7F814A3F52200DE7B18 /* README */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = README; sourceTree = ""; }; + 8570ECDE1DA1916700099FC2 /* GetName.nib */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = GetName.nib; path = Resources/GetName.nib; sourceTree = ""; }; + 8570ECDF1DA1916700099FC2 /* MainMenu.nib */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = MainMenu.nib; path = Resources/MainMenu.nib; sourceTree = ""; }; + 8570ECE21DA1917D00099FC2 /* InfoPlist.strings */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = InfoPlist.strings; path = Resources/InfoPlist.strings; sourceTree = ""; }; + 85E8F2C916EFCF6C00E03CA9 /* FTP.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = FTP.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 85E8F32416EFD9D000E03CA9 /* ChangeLog */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = ChangeLog; sourceTree = ""; }; + 85FC29710DD7B28300A80101 /* FTP_icon_osx.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = FTP_icon_osx.icns; sourceTree = ""; }; + F56A03FB080AC70701A80101 /* localclient.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = localclient.m; sourceTree = ""; }; + F56A03FD080AC71101A80101 /* localclient.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = localclient.h; sourceTree = ""; }; + F5BE3AF6080C6A3601A80101 /* fileTable.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = fileTable.h; sourceTree = ""; }; + F5BE3AF7080C6A3601A80101 /* fileTable.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = fileTable.m; sourceTree = ""; }; + F5C0879F08A0C47B01A8012F /* arrow_right.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = arrow_right.tiff; sourceTree = ""; }; + F5C087A108A0C4AF01A8012F /* arrow_left.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = arrow_left.tiff; sourceTree = ""; }; + F5C84D6008142DF201A80101 /* fileElement.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = fileElement.h; sourceTree = ""; }; + F5C84D6108142DF201A80101 /* fileElement.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = fileElement.m; sourceTree = ""; }; + F5EFB6450818FE6001A80101 /* client.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = client.m; sourceTree = ""; }; + F5EFB6470818FE6E01A80101 /* client.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = client.h; sourceTree = ""; }; + F5F5F93707FD8CAD01A80101 /* AppController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = AppController.h; sourceTree = ""; }; + F5F5F93807FD8CAD01A80101 /* AppController.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = AppController.m; sourceTree = ""; }; + F5F5F93907FD8CAD01A80101 /* ftpclient.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = ftpclient.h; sourceTree = ""; }; + F5F5F93A07FD8CAD01A80101 /* ftpclient.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = ftpclient.m; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 85E8F2C216EFCF6C00E03CA9 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 85E8F2C316EFCF6C00E03CA9 /* Cocoa.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 080E96DDFE201D6D7F000001 /* Classes */ = { + isa = PBXGroup; + children = ( + 8531288B1767CADA00F56C92 /* GetNameController.h */, + 8531288C1767CADA00F56C92 /* GetNameController.m */, + F5F5F93707FD8CAD01A80101 /* AppController.h */, + F5F5F93807FD8CAD01A80101 /* AppController.m */, + F5F5F93907FD8CAD01A80101 /* ftpclient.h */, + F5F5F93A07FD8CAD01A80101 /* ftpclient.m */, + F56A03FB080AC70701A80101 /* localclient.m */, + F56A03FD080AC71101A80101 /* localclient.h */, + F5BE3AF6080C6A3601A80101 /* fileTable.h */, + F5BE3AF7080C6A3601A80101 /* fileTable.m */, + F5C84D6008142DF201A80101 /* fileElement.h */, + F5C84D6108142DF201A80101 /* fileElement.m */, + F5EFB6470818FE6E01A80101 /* client.h */, + F5EFB6450818FE6001A80101 /* client.m */, + ); + name = Classes; + sourceTree = ""; + }; + 1058C7A0FEA54F0111CA2CBB /* Linked Frameworks */ = { + isa = PBXGroup; + children = ( + 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */, + ); + name = "Linked Frameworks"; + sourceTree = ""; + }; + 1058C7A2FEA54F0111CA2CBB /* Other Frameworks */ = { + isa = PBXGroup; + children = ( + 29B97325FDCFA39411CA2CEA /* Foundation.framework */, + 29B97324FDCFA39411CA2CEA /* AppKit.framework */, + ); + name = "Other Frameworks"; + sourceTree = ""; + }; + 19C28FACFE9D520D11CA2CBB /* Products */ = { + isa = PBXGroup; + children = ( + 85E8F2C916EFCF6C00E03CA9 /* FTP.app */, + ); + name = Products; + sourceTree = ""; + }; + 29B97314FDCFA39411CA2CEA /* FTP */ = { + isa = PBXGroup; + children = ( + 080E96DDFE201D6D7F000001 /* Classes */, + 29B97315FDCFA39411CA2CEA /* Other Sources */, + 29B97317FDCFA39411CA2CEA /* Resources */, + 29B97323FDCFA39411CA2CEA /* Frameworks */, + 19C28FACFE9D520D11CA2CBB /* Products */, + ); + name = FTP; + sourceTree = ""; + }; + 29B97315FDCFA39411CA2CEA /* Other Sources */ = { + isa = PBXGroup; + children = ( + 29B97316FDCFA39411CA2CEA /* main.m */, + ); + name = "Other Sources"; + sourceTree = ""; + }; + 29B97317FDCFA39411CA2CEA /* Resources */ = { + isa = PBXGroup; + children = ( + 8534AFA81DAB81DC005F5ECD /* Localizable.strings */, + 8570ECE21DA1917D00099FC2 /* InfoPlist.strings */, + 8570ECDE1DA1916700099FC2 /* GetName.nib */, + 8570ECDF1DA1916700099FC2 /* MainMenu.nib */, + 85E8F32416EFD9D000E03CA9 /* ChangeLog */, + 853FB7F814A3F52200DE7B18 /* README */, + 85FC29710DD7B28300A80101 /* FTP_icon_osx.icns */, + F5C0879F08A0C47B01A8012F /* arrow_right.tiff */, + F5C087A108A0C4AF01A8012F /* arrow_left.tiff */, + ); + name = Resources; + sourceTree = ""; + }; + 29B97323FDCFA39411CA2CEA /* Frameworks */ = { + isa = PBXGroup; + children = ( + 1058C7A0FEA54F0111CA2CBB /* Linked Frameworks */, + 1058C7A2FEA54F0111CA2CBB /* Other Frameworks */, + ); + name = Frameworks; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXHeadersBuildPhase section */ + 85E8F2AC16EFCF6C00E03CA9 /* Headers */ = { + isa = PBXHeadersBuildPhase; + buildActionMask = 2147483647; + files = ( + 85E8F2AD16EFCF6C00E03CA9 /* AppController.h in Headers */, + 85E8F2AE16EFCF6C00E03CA9 /* ftpclient.h in Headers */, + 85E8F2AF16EFCF6C00E03CA9 /* localclient.h in Headers */, + 85E8F2B016EFCF6C00E03CA9 /* fileTable.h in Headers */, + 85E8F2B116EFCF6C00E03CA9 /* fileElement.h in Headers */, + 85E8F2B216EFCF6C00E03CA9 /* client.h in Headers */, + 8531288D1767CADA00F56C92 /* GetNameController.h in Headers */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXHeadersBuildPhase section */ + +/* Begin PBXNativeTarget section */ + 85E8F2AB16EFCF6C00E03CA9 /* FTP */ = { + isa = PBXNativeTarget; + buildConfigurationList = 85E8F2C416EFCF6C00E03CA9 /* Build configuration list for PBXNativeTarget "FTP" */; + buildPhases = ( + 85E8F2AC16EFCF6C00E03CA9 /* Headers */, + 85E8F2B316EFCF6C00E03CA9 /* Resources */, + 85E8F2BA16EFCF6C00E03CA9 /* Sources */, + 85E8F2C216EFCF6C00E03CA9 /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = FTP; + productInstallPath = "$(HOME)/Applications"; + productName = FTP; + productReference = 85E8F2C916EFCF6C00E03CA9 /* FTP.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 29B97313FDCFA39411CA2CEA /* Project object */ = { + isa = PBXProject; + buildConfigurationList = 85A6DBE310D43D010048FE0B /* Build configuration list for PBXProject "FTP" */; + compatibilityVersion = "Xcode 2.4"; + hasScannedForEncodings = 1; + knownRegions = ( + English, + Japanese, + French, + German, + Italian, + ); + mainGroup = 29B97314FDCFA39411CA2CEA /* FTP */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 85E8F2AB16EFCF6C00E03CA9 /* FTP */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 85E8F2B316EFCF6C00E03CA9 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 85E8F2B616EFCF6C00E03CA9 /* arrow_right.tiff in Resources */, + 85E8F2B716EFCF6C00E03CA9 /* arrow_left.tiff in Resources */, + 85E8F2B816EFCF6C00E03CA9 /* FTP_icon_osx.icns in Resources */, + 85E8F2B916EFCF6C00E03CA9 /* README in Resources */, + 85E8F32516EFD9D000E03CA9 /* ChangeLog in Resources */, + 8570ECE01DA1916700099FC2 /* GetName.nib in Resources */, + 8570ECE11DA1916700099FC2 /* MainMenu.nib in Resources */, + 8570ECE31DA1917D00099FC2 /* InfoPlist.strings in Resources */, + 8534AFAA1DAB81DC005F5ECD /* Localizable.strings in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 85E8F2BA16EFCF6C00E03CA9 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 85E8F2BB16EFCF6C00E03CA9 /* main.m in Sources */, + 85E8F2BC16EFCF6C00E03CA9 /* AppController.m in Sources */, + 85E8F2BD16EFCF6C00E03CA9 /* ftpclient.m in Sources */, + 85E8F2BE16EFCF6C00E03CA9 /* localclient.m in Sources */, + 85E8F2BF16EFCF6C00E03CA9 /* fileTable.m in Sources */, + 85E8F2C016EFCF6C00E03CA9 /* fileElement.m in Sources */, + 85E8F2C116EFCF6C00E03CA9 /* client.m in Sources */, + 8531288E1767CADB00F56C92 /* GetNameController.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 8534AFA81DAB81DC005F5ECD /* Localizable.strings */ = { + isa = PBXVariantGroup; + children = ( + 8534AFA91DAB81DC005F5ECD /* English */, + 8534AFAB1DAB81F5005F5ECD /* German */, + 8534AFAC1DAB8213005F5ECD /* Italian */, + ); + name = Localizable.strings; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 85A6DBE410D43D010048FE0B /* Development */ = { + isa = XCBuildConfiguration; + buildSettings = { + }; + name = Development; + }; + 85A6DBE510D43D010048FE0B /* Deployment */ = { + isa = XCBuildConfiguration; + buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; + }; + name = Deployment; + }; + 85A6DBE610D43D010048FE0B /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + }; + name = Default; + }; + 85E8F2C516EFCF6C00E03CA9 /* Development */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = NO; + FRAMEWORK_SEARCH_PATHS = ""; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_SYMBOLS_PRIVATE_EXTERN = NO; + HEADER_SEARCH_PATHS = ""; + INFOPLIST_FILE = "Info-FTP.plist"; + INSTALL_PATH = "$(HOME)/Applications"; + LIBRARY_SEARCH_PATHS = ""; + OTHER_CFLAGS = ""; + OTHER_LDFLAGS = ""; + PRODUCT_NAME = FTP; + SECTORDER_FLAGS = ""; + WARNING_CFLAGS = ( + "-Wmost", + "-Wno-four-char-constants", + "-Wno-unknown-pragmas", + ); + WRAPPER_EXTENSION = app; + ZERO_LINK = YES; + }; + name = Development; + }; + 85E8F2C616EFCF6C00E03CA9 /* Deployment */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = YES; + FRAMEWORK_SEARCH_PATHS = ""; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_SYMBOLS_PRIVATE_EXTERN = NO; + HEADER_SEARCH_PATHS = ""; + INFOPLIST_FILE = "Info-FTP.plist"; + INSTALL_PATH = "$(HOME)/Applications"; + LIBRARY_SEARCH_PATHS = ""; + OTHER_CFLAGS = ""; + OTHER_LDFLAGS = ""; + PRODUCT_NAME = FTP; + SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SECTORDER_FLAGS = ""; + WARNING_CFLAGS = ( + "-Wmost", + "-Wno-four-char-constants", + "-Wno-unknown-pragmas", + ); + WRAPPER_EXTENSION = app; + ZERO_LINK = NO; + }; + name = Deployment; + }; + 85E8F2C716EFCF6C00E03CA9 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + ARCHS = "$(NATIVE_ARCH_ACTUAL)"; + FRAMEWORK_SEARCH_PATHS = ""; + GCC_SYMBOLS_PRIVATE_EXTERN = NO; + HEADER_SEARCH_PATHS = ""; + INFOPLIST_FILE = "Info-FTP.plist"; + INSTALL_PATH = "$(HOME)/Applications"; + LIBRARY_SEARCH_PATHS = ""; + OTHER_CFLAGS = ""; + OTHER_LDFLAGS = ""; + PRODUCT_NAME = FTP; + SECTORDER_FLAGS = ""; + WARNING_CFLAGS = ( + "-Wmost", + "-Wno-four-char-constants", + "-Wno-unknown-pragmas", + ); + WRAPPER_EXTENSION = app; + }; + name = Default; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 85A6DBE310D43D010048FE0B /* Build configuration list for PBXProject "FTP" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 85A6DBE410D43D010048FE0B /* Development */, + 85A6DBE510D43D010048FE0B /* Deployment */, + 85A6DBE610D43D010048FE0B /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 85E8F2C416EFCF6C00E03CA9 /* Build configuration list for PBXNativeTarget "FTP" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 85E8F2C516EFCF6C00E03CA9 /* Development */, + 85E8F2C616EFCF6C00E03CA9 /* Deployment */, + 85E8F2C716EFCF6C00E03CA9 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; +/* End XCConfigurationList section */ + }; + rootObject = 29B97313FDCFA39411CA2CEA /* Project object */; +} diff -Nru ftp.app-0.5/GetNameController.h ftp.app-0.6/GetNameController.h --- ftp.app-0.5/GetNameController.h 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/GetNameController.h 2017-01-19 09:34:42.000000000 +0000 @@ -2,7 +2,7 @@ Project: FTP - Copyright (C) 2013 Free Software Foundation + Copyright (C) 2013-2016 Free Software Foundation Author: Riccardo Mottola @@ -43,6 +43,9 @@ IBOutlet NSPanel *panel; IBOutlet NSTextField *textField; IBOutlet NSTextField *messageField; + IBOutlet NSTextField *labelField; + IBOutlet NSButton *cancelButton; + IBOutlet NSButton *okButton; NSInteger returnCode; } diff -Nru ftp.app-0.5/GetNameController.m ftp.app-0.6/GetNameController.m --- ftp.app-0.5/GetNameController.m 2014-05-24 20:30:51.000000000 +0000 +++ ftp.app-0.6/GetNameController.m 2017-01-19 09:34:43.000000000 +0000 @@ -2,7 +2,7 @@ Project: FTP - Copyright (C) 2013 Free Software Foundation + Copyright (C) 2013-2016 Free Software Foundation Author: Riccardo Mottola @@ -38,6 +38,10 @@ { [NSBundle loadNibNamed: @"GetName" owner: self]; [panel setDelegate: self]; + + [labelField setStringValue:NSLocalizedString(@"Name:", @"Name:")]; + [cancelButton setTitle:NSLocalizedString(@"Cancel", @"Cancel")]; + [okButton setTitle:NSLocalizedString(@"Ok", @"Ok")]; } return self; } diff -Nru ftp.app-0.5/GNUmakefile ftp.app-0.6/GNUmakefile --- ftp.app-0.5/GNUmakefile 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/GNUmakefile 2017-01-19 09:34:43.000000000 +0000 @@ -3,6 +3,15 @@ # ifeq ($(GNUSTEP_MAKEFILES),) GNUSTEP_MAKEFILES := $(shell gnustep-config --variable=GNUSTEP_MAKEFILES 2>/dev/null) + ifeq ($(GNUSTEP_MAKEFILES),) + $(warning ) + $(warning Unable to obtain GNUSTEP_MAKEFILES setting from gnustep-config!) + $(warning Perhaps gnustep-make is not properly installed,) + $(warning so gnustep-config is not in your PATH.) + $(warning ) + $(warning Your PATH is currently $(PATH)) + $(warning ) + endif endif ifeq ($(GNUSTEP_MAKEFILES),) $(error You need to set GNUSTEP_MAKEFILES before compiling!) @@ -13,7 +22,7 @@ # # Application # -VERSION = 0.5 +VERSION = 0.6 PACKAGE_NAME = FTP APP_NAME = FTP FTP_APPLICATION_ICON = FTP_icon_gs.tif @@ -25,9 +34,9 @@ FTP_RESOURCE_FILES = \ Resources/FTP.gorm \ Resources/GetName.gorm \ +Resources/FTP_icon_gs.tif \ Resources/arrow_left.tiff \ -Resources/arrow_right.tiff \ -Resources/FTP_icon_gs.tif +Resources/arrow_right.tiff # @@ -35,24 +44,24 @@ # FTP_HEADER_FILES = \ AppController.h \ -GetNameController.h \ -ftpclient.h \ -localclient.h \ -fileTable.h \ +client.h \ fileElement.h \ -client.h +fileTable.h \ +ftpclient.h \ +GetNameController.h \ +localclient.h # -# Class files +# Objective-C Class files # FTP_OBJC_FILES = \ AppController.m \ -GetNameController.m \ -ftpclient.m \ -localclient.m \ -fileTable.m \ +client.m \ fileElement.m \ -client.m +fileTable.m \ +ftpclient.m \ +GetNameController.m \ +localclient.m # # Other sources diff -Nru ftp.app-0.5/Info-FTP.plist ftp.app-0.6/Info-FTP.plist --- ftp.app-0.5/Info-FTP.plist 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/Info-FTP.plist 2017-08-31 07:14:01.000000000 +0000 @@ -7,7 +7,9 @@ CFBundleExecutable FTP CFBundleIconFile - FTP_icon_osx.icns + FTP_icon_osx + CFBundleIdentifier + org.gap.FTP CFBundleInfoDictionaryVersion 6.0 CFBundlePackageType @@ -15,7 +17,7 @@ CFBundleSignature ???? CFBundleVersion - 0.5 + 0.6 NSMainNibFile MainMenu NSPrincipalClass diff -Nru ftp.app-0.5/localclient.m ftp.app-0.6/localclient.m --- ftp.app-0.5/localclient.m 2014-05-24 20:30:51.000000000 +0000 +++ ftp.app-0.6/localclient.m 2017-01-19 09:34:43.000000000 +0000 @@ -1,7 +1,7 @@ /* Project: FTP - Copyright (C) 2005-2013 Riccardo Mottola + Copyright (C) 2005-2016 Riccardo Mottola Author: Riccardo Mottola @@ -41,8 +41,7 @@ /* creates a new directory - tries to guess if the given dir is relative (no starting /) or absolute - Is this portable to non-unix OS's? + If the path is absolute, use it directly, else append to wokding directory */ - (BOOL)createNewDir:(NSString *)dir { @@ -51,7 +50,7 @@ BOOL isDir; fm = [NSFileManager defaultManager]; - if ([dir hasPrefix:@"/"]) + if ([dir isAbsolutePath]) { NSLog(@"%@ is an absolute path", dir); localPath = dir; @@ -69,7 +68,7 @@ return YES; } -- (NSArray *)dirContents +- (bycopy NSArray *)dirContents { NSFileManager *fm; NSArray *fileNames; @@ -100,14 +99,18 @@ return [NSArray arrayWithArray:listArr]; } -- (void)deleteFile:(FileElement *)file beingAt:(int)depth +- (BOOL)deleteFile:(FileElement *)file beingAt:(int)depth { NSFileManager *fm; fm = [NSFileManager defaultManager]; if ([fm removeFileAtPath:[file path] handler:nil] == NO) - NSLog(@"an error occoured during local delete"); + { + NSLog(@"an error occoured during local delete"); + return NO; + } + return YES; } diff -Nru ftp.app-0.5/README ftp.app-0.6/README --- ftp.app-0.5/README 2014-05-24 20:30:52.000000000 +0000 +++ ftp.app-0.6/README 2016-08-02 21:06:32.000000000 +0000 @@ -1,6 +1,3 @@ NOTES -To compile on windows, please add the following to your GNUmakefile.preamble - -ADDITIONAL_GUI_LIBS += -lwinmm - +No specific notes for Windows compilation currently. diff -Nru ftp.app-0.5/Resources/English.lproj/Localizable.strings ftp.app-0.6/Resources/English.lproj/Localizable.strings --- ftp.app-0.5/Resources/English.lproj/Localizable.strings 1970-01-01 00:00:00.000000000 +0000 +++ ftp.app-0.6/Resources/English.lproj/Localizable.strings 2017-01-19 09:34:42.000000000 +0000 @@ -0,0 +1,27 @@ +/* menu */ +"Local" = "Local"; +"Remote" = "Remote"; +"Rename..." = "Rename..."; +"New Folder..." = "New Folder..."; +"Delete" = "Delete"; +"Refresh" = "Refresh"; + +/* Connection panel */ +"Server Address and Port" = "Server Address and Port"; +"Account" = "Account"; +"Connect" = "Connect"; +"Anonymous" = "Anonymous"; +"Connect (action)" = "Connect"; + +/* main window */ +"local view" = "Local View"; +"remote view" = "Remote View"; +"Name" = "Name"; + +/* Log */ +"Connection Log" = "Connection Log"; + +/* Get Name */ +"Name:" = "Name:"; +"Cancel" = "Cancel"; +"Ok" = "Ok"; \ No newline at end of file diff -Nru ftp.app-0.5/Resources/German.lproj/Localizable.strings ftp.app-0.6/Resources/German.lproj/Localizable.strings --- ftp.app-0.5/Resources/German.lproj/Localizable.strings 1970-01-01 00:00:00.000000000 +0000 +++ ftp.app-0.6/Resources/German.lproj/Localizable.strings 2017-01-19 09:34:42.000000000 +0000 @@ -0,0 +1,22 @@ +/* menu */ +"Local" = "Lokal"; +"Remote" = "Fern"; +"Rename..." = "Umbenennen..."; +"New Folder..." = "Neuer Ordner..."; +"Delete" = "Delete"; +"Refresh" = "Aktualisieren"; + +/* Connection panel */ +"Server Address and Port" = "Server Addresse und Port"; +"Account" = "Konto"; +"Connect" = "Verbindung"; +"Anonymous" = "Anonym"; +"Connect (action)" = "Verbinde"; + +/* Log */ +"Connection Log" = "Verbindungslog"; + +/* Get Name */ +"Name:" = "Name:"; +"Cancel" = "Abbrechen"; +"Ok" = "Ok"; \ No newline at end of file diff -Nru ftp.app-0.5/Resources/GetName.nib/classes.nib ftp.app-0.6/Resources/GetName.nib/classes.nib --- ftp.app-0.5/Resources/GetName.nib/classes.nib 1970-01-01 00:00:00.000000000 +0000 +++ ftp.app-0.6/Resources/GetName.nib/classes.nib 2017-01-19 09:34:42.000000000 +0000 @@ -0,0 +1,20 @@ +{ + IBClasses = ( + {CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; }, + { + ACTIONS = {cancelPressed = id; okPressed = id; }; + CLASS = GetNameController; + LANGUAGE = ObjC; + OUTLETS = { + cancelButton = NSButton; + labelField = NSTextField; + messageField = NSTextField; + okButton = NSButton; + panel = NSPanel; + textField = NSTextField; + }; + SUPERCLASS = NSObject; + } + ); + IBVersion = 1; +} \ No newline at end of file diff -Nru ftp.app-0.5/Resources/GetName.nib/info.nib ftp.app-0.6/Resources/GetName.nib/info.nib --- ftp.app-0.5/Resources/GetName.nib/info.nib 1970-01-01 00:00:00.000000000 +0000 +++ ftp.app-0.6/Resources/GetName.nib/info.nib 2017-01-19 09:34:42.000000000 +0000 @@ -0,0 +1,18 @@ + + + + + IBDocumentLocation + 168 85 356 240 0 0 1440 938 + IBFramework Version + 489.0 + IBOldestOS + 1 + IBOpenObjects + + 6 + + IBSystem Version + 8S165 + + Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/Resources/GetName.nib/keyedobjects.nib and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/Resources/GetName.nib/keyedobjects.nib differ Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/Resources/GetName.nib/objects.nib and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/Resources/GetName.nib/objects.nib differ Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/Resources/InfoPlist.strings and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/Resources/InfoPlist.strings differ diff -Nru ftp.app-0.5/Resources/Italian.lproj/Localizable.strings ftp.app-0.6/Resources/Italian.lproj/Localizable.strings --- ftp.app-0.5/Resources/Italian.lproj/Localizable.strings 1970-01-01 00:00:00.000000000 +0000 +++ ftp.app-0.6/Resources/Italian.lproj/Localizable.strings 2017-01-19 09:34:42.000000000 +0000 @@ -0,0 +1,27 @@ +/* menu */ +"Local" = "Local"; +"Remote" = "Remote"; +"Rename..." = "Rename..."; +"New Folder..." = "New Folder..."; +"Delete" = "Delete"; +"Refresh" = "Refresh"; + +/* Connection panel */ +"Server Address and Port" = "Indirizzo server e porta"; +"Account" = "Credenziali"; +"Connect" = "Connessione"; +"Anonymous" = "Anonimo"; +"Connect (action)" = "Connetti"; + +/* main window */ +"local view" = "Vista Locale"; +"remote view" = "Vista Remota"; +"Name" = "Nome"; + +/* Log */ +"Connection Log" = "Log Connessione"; + +/* Get Name */ +"Name:" = "Nome:"; +"Cancel" = "Annulla"; +"Ok" = "Ok"; \ No newline at end of file diff -Nru ftp.app-0.5/Resources/MainMenu.nib/classes.nib ftp.app-0.6/Resources/MainMenu.nib/classes.nib --- ftp.app-0.5/Resources/MainMenu.nib/classes.nib 1970-01-01 00:00:00.000000000 +0000 +++ ftp.app-0.6/Resources/MainMenu.nib/classes.nib 2017-01-19 09:34:42.000000000 +0000 @@ -0,0 +1,65 @@ +{ + IBClasses = ( + { + ACTIONS = { + anonymousConn = id; + cancelConn = id; + changePathFromMenu = id; + connectConn = id; + disconnect = id; + downloadButton = id; + listDoubleClick = id; + localDelete = id; + localNewFolder = id; + localRefresh = id; + localRename = id; + prefCancel = id; + prefSave = id; + remoteDelete = id; + remoteNewFolder = id; + remoteRefresh = id; + remoteRename = id; + showConnPanel = id; + showFtpLog = id; + showPrefPanel = id; + uploadButton = id; + }; + CLASS = AppController; + LANGUAGE = ObjC; + OUTLETS = { + buttDownload = NSButton; + buttUpload = NSButton; + connAccountBox = NSBox; + connAddress = NSTextField; + connAnon = NSButton; + connCancelButt = NSButton; + connConnectButt = NSButton; + connPass = NSTextField; + connPort = NSTextField; + connServerBox = NSBox; + connUser = NSTextField; + connectPanel = NSPanel; + infoMessage = NSTextField; + infoSize = NSTextField; + infoSpeed = NSTextField; + localPath = NSPopUpButton; + localView = NSTableView; + logTextField = NSTextView; + logWin = NSWindow; + mainMenu = NSMenu; + mainWin = NSWindow; + portType = NSMatrix; + prefCancelButt = NSButton; + prefPanel = NSPanel; + prefSaveButt = NSButton; + progBar = NSProgressIndicator; + remotePath = NSPopUpButton; + remoteView = NSTableView; + }; + SUPERCLASS = NSObject; + }, + {CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; }, + {CLASS = fileTransmitParms; LANGUAGE = ObjC; SUPERCLASS = NSObject; } + ); + IBVersion = 1; +} \ No newline at end of file diff -Nru ftp.app-0.5/Resources/MainMenu.nib/info.nib ftp.app-0.6/Resources/MainMenu.nib/info.nib --- ftp.app-0.5/Resources/MainMenu.nib/info.nib 1970-01-01 00:00:00.000000000 +0000 +++ ftp.app-0.6/Resources/MainMenu.nib/info.nib 2017-01-19 09:34:42.000000000 +0000 @@ -0,0 +1,27 @@ + + + + + IBDocumentLocation + 68 91 356 240 0 0 1440 938 + IBEditorPositions + + 29 + 194 678 369 44 0 0 1440 938 + + IBFramework Version + 489.0 + IBOldestOS + 1 + IBOpenObjects + + 29 + 274 + 218 + 21 + 206 + + IBSystem Version + 8S165 + + Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/Resources/MainMenu.nib/keyedobjects.nib and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/Resources/MainMenu.nib/keyedobjects.nib differ Binary files /tmp/tmpVwntao/LKRSElgC_i/ftp.app-0.5/Resources/MainMenu.nib/objects.nib and /tmp/tmpVwntao/9MXx8HG1Wf/ftp.app-0.6/Resources/MainMenu.nib/objects.nib differ