View | Details | Raw Unified | Return to bug 210968
Collapse All | Expand All

(-)/usr/wip/graphics/qiviewer/files/patch-main.cpp (+13 lines)
Line 0 Link Here
1
--- main.cpp.orig	2011-05-19 03:38:25 UTC
2
+++ main.cpp
3
@@ -115,6 +115,10 @@ int main(int argc, char *argv[])
4
 
5
     else if (next_option == -1)
6
     {
7
+	// Strip file://, added by some file browsers
8
+	if ( memcmp(argv[1], "file://", 7) == 0 )
9
+	    memmove(argv[1], argv[1]+7, strlen(argv[1]) - 6);
10
+	puts(argv[1]);
11
         MainWindow imageViewer;
12
         if (QApplication::arguments().size() > 1)
13
             imageViewer.openImageFromCommandLine(QApplication::arguments());

Return to bug 210968