aboutsummaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
Diffstat (limited to 'Source')
-rw-r--r--Source/SPAppController.m6
1 files changed, 5 insertions, 1 deletions
diff --git a/Source/SPAppController.m b/Source/SPAppController.m
index 30429d79..7ab59084 100644
--- a/Source/SPAppController.m
+++ b/Source/SPAppController.m
@@ -653,7 +653,11 @@ YY_BUFFER_STATE yy_scan_string (const char *);
NSString *command = [url host];
NSString *passedProcessID = [url user];
NSArray *parameter;
- NSArray *pathComponents = [[url absoluteString] pathComponents];
+ NSArray *pathComponents;
+ if([[url absoluteString] hasSuffix:@"/"])
+ pathComponents = [[[url absoluteString] substringToIndex:[[url absoluteString] length]-1] pathComponents];
+ else
+ pathComponents = [[url absoluteString] pathComponents];
if([pathComponents count] > 2)
parameter = [pathComponents subarrayWithRange:NSMakeRange(2, [pathComponents count]-2)];