summaryrefslogtreecommitdiff
path: root/cocoa/NetsurfApp.m
diff options
context:
space:
mode:
authorFran├žois Revel <mmu_man@netsurf-browser.org>2011-04-26 22:40:17 +0000
committerFran├žois Revel <mmu_man@netsurf-browser.org>2011-04-26 22:40:17 +0000
commitd0e7a5ecacc8692b533c8102bfa6b2267f309ab9 (patch)
tree328054086db6062b44076480bbe4beb412983aba /cocoa/NetsurfApp.m
parent06f80d731fce0a96fedc5dcce90fd864a4d7a409 (diff)
downloadnetsurf-d0e7a5ecacc8692b533c8102bfa6b2267f309ab9.tar.gz
netsurf-d0e7a5ecacc8692b533c8102bfa6b2267f309ab9.tar.bz2
Skip command line arguments starting with - (including the annoying -psn_0_... one when launched from Finder).
svn path=/trunk/netsurf/; revision=12242
Diffstat (limited to 'cocoa/NetsurfApp.m')
-rw-r--r--cocoa/NetsurfApp.m3
1 files changed, 3 insertions, 0 deletions
diff --git a/cocoa/NetsurfApp.m b/cocoa/NetsurfApp.m
index 399ea11d1..8897eb4b4 100644
--- a/cocoa/NetsurfApp.m
+++ b/cocoa/NetsurfApp.m
@@ -182,6 +182,9 @@ int main( int argc, char **argv )
NSApplication *app = cocoa_prepare_app();
for (int i = 1; i < argc; i++) {
+ /* skip -psn_* and other possible options */
+ if (argv[i][0] == '-')
+ continue;
browser_window_create( argv[i], NULL, NULL, true, false );
}