Browse Source

Add 'tdesu' to tdeioslave_file mount/umount command on openbsd

tags/r14.0.0
François Andriot 4 years ago
parent
commit
b588c6e6bd
1 changed files with 7 additions and 0 deletions
  1. 7
    0
      tdeioslave/file/file.cc

+ 7
- 0
tdeioslave/file/file.cc View File

@@ -1455,6 +1455,9 @@ void FileProtocol::mount( bool _ro, const char *_fstype, const TQString& _dev, c
1455 1455
                                 dev.data()
1456 1456
                                 point.data()
1457 1457
                                 tmp );
1458
+#elif defined(__OpenBSD__)
1459
+              buffer.sprintf( "%s %s %s -t %s %s %s 2>%s", "tdesu", mountProg.latin1(), readonly.data(),
1460
+                              fstype.data(), dev.data(), point.data(), tmp );
1458 1461
 #else
1459 1462
               buffer.sprintf( "%s %s -t %s %s %s 2>%s", mountProg.latin1(), readonly.data(),
1460 1463
                               fstype.data(), dev.data(), point.data(), tmp );
@@ -1614,7 +1617,11 @@ void FileProtocol::unmount( const TQString& _point )
1614 1617
         error( TDEIO::ERR_COULD_NOT_UNMOUNT, i18n("Could not find program \"umount\""));
1615 1618
         return;
1616 1619
     }
1620
+#ifdef __OpenBSD__
1621
+    buffer.sprintf( "%s %s %s 2>%s", "tdesu", umountProg.latin1(), TQFile::encodeName(TDEProcess::quote(_point)).data(), tmp );
1622
+#else
1617 1623
     buffer.sprintf( "%s %s 2>%s", umountProg.latin1(), TQFile::encodeName(TDEProcess::quote(_point)).data(), tmp );
1624
+#endif
1618 1625
     system( buffer.data() );
1619 1626
 #endif /* HAVE_VOLMGT */
1620 1627
 

Loading…
Cancel
Save