Commits

Thomas Friedrichsmeier  committed 466d817

That still was not right. We should quit only, if *none* of the specified urls made any sense.

svn path=/trunk/KDE/kdebase/apps/kwrite/; revision=741918

  • Participants
  • Parent commits 33984ae

Comments (0)

Files changed (1)

File kwrite/kwritemain.cpp

     }
     else
     {
+      int docs_opened = 0;
       for ( int z = 0; z < args->count(); z++ )
       {
         // this file is no local dir, open it, else warn
 
         if (noDir)
         {
+          ++docs_opened;
           KWrite *t = new KWrite();
 
 //          if (Kate::document (t->view()->document()))
         else
         {
           KMessageBox::sorry(0, i18n("The file '%1' could not be opened: it is not a normal file, it is a folder.", args->url(z).url()));
-          return 1; // see http://bugs.kde.org/show_bug.cgi?id=124708
         }
       }
+      if (!docs_opened) return 1; // see http://bugs.kde.org/show_bug.cgi?id=124708
     }
   }