use the Transmission website for checking port status; stop previous port check before starting a new one

This commit is contained in:
Mitchell Livingston
2007-12-18 20:02:49 +00:00
parent 307ddcc74f
commit 896a19ae28
4 changed files with 51 additions and 56 deletions

View File

@@ -24,18 +24,26 @@
#import <Cocoa/Cocoa.h>
typedef enum { PORT_STATUS_OPEN, PORT_STATUS_STEALTH, PORT_STATUS_CLOSED, PORT_STATUS_ERROR } port_status_t;
typedef enum
{
PORT_STATUS_OPEN,
PORT_STATUS_CLOSED,
PORT_STATUS_ERROR
} port_status_t;
@interface PortChecker : NSObject
{
id fDelegate;
port_status_t fStatus;
NSURLConnection * fConnection;
NSMutableData * fPortProbeData;
}
- (id) initWithDelegate: (id) delegate;
- (void) probePort: (int) portNumber;
- (void) endProbe;
- (void) callBackWithStatus: (port_status_t) status;
- (port_status_t) status;